From f31fb9ee177c25a3af07594b73c18720bac24384 Mon Sep 17 00:00:00 2001 From: Abdoulbari ZAKIR Date: Fri, 22 Sep 2023 17:23:49 +0200 Subject: [PATCH] smell code --- src/solver/optimisation/constraints/ConstraintBuilder.h | 7 +------ ...t_construction_matrice_des_contraintes_cas_lineaire.cpp | 5 ----- 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/src/solver/optimisation/constraints/ConstraintBuilder.h b/src/solver/optimisation/constraints/ConstraintBuilder.h index 5fa26cd3cb..788a075bfa 100644 --- a/src/solver/optimisation/constraints/ConstraintBuilder.h +++ b/src/solver/optimisation/constraints/ConstraintBuilder.h @@ -4,8 +4,6 @@ #include "../opt_structure_probleme_a_resoudre.h" #include "../opt_rename_problem.h" #include "../opt_fonctions.h" - -// TODO remove relative include #include "../../simulation/sim_structure_probleme_economique.h" #include @@ -269,10 +267,7 @@ class ConstraintBuilder class ConstraintBuilderInvalidOperator : public std::runtime_error { public: - explicit ConstraintBuilderInvalidOperator(const std::string& error_message) : - std::runtime_error(error_message) - { - } + using std::runtime_error::std::runtime_error; }; /*! diff --git a/src/solver/optimisation/opt_construction_matrice_des_contraintes_cas_lineaire.cpp b/src/solver/optimisation/opt_construction_matrice_des_contraintes_cas_lineaire.cpp index 7c5420a265..d9fae6948b 100644 --- a/src/solver/optimisation/opt_construction_matrice_des_contraintes_cas_lineaire.cpp +++ b/src/solver/optimisation/opt_construction_matrice_des_contraintes_cas_lineaire.cpp @@ -54,9 +54,6 @@ using namespace Antares::Data; void OPT_ConstruireLaMatriceDesContraintesDuProblemeLineaire(PROBLEME_HEBDO* problemeHebdo, Solver::IResultWriter& writer) { - int var; - - PROBLEME_ANTARES_A_RESOUDRE* ProblemeAResoudre = problemeHebdo->ProblemeAResoudre.get(); int nombreDePasDeTempsDUneJournee = problemeHebdo->NombreDePasDeTempsDUneJournee; @@ -123,8 +120,6 @@ void OPT_ConstruireLaMatriceDesContraintesDuProblemeLineaire(PROBLEME_HEBDO* pro if (nombreDePasDeTempsPourUneOptimisation > nombreDePasDeTempsDUneJournee) { - CORRESPONDANCES_DES_CONTRAINTES_HEBDOMADAIRES& CorrespondanceCntNativesCntOptimHebdomadaires - = problemeHebdo->CorrespondanceCntNativesCntOptimHebdomadaires; for (uint32_t cntCouplante = 0; cntCouplante < problemeHebdo->NombreDeContraintesCouplantes; cntCouplante++) {