diff --git a/examples/dgfip_c/ml_primitif/2020.expected/fuzzer_812.m_test.tgv b/examples/dgfip_c/ml_primitif/2020.expected/fuzzer_812.m_test.tgv index bb10f2706..0fc541d58 100644 Binary files a/examples/dgfip_c/ml_primitif/2020.expected/fuzzer_812.m_test.tgv and b/examples/dgfip_c/ml_primitif/2020.expected/fuzzer_812.m_test.tgv differ diff --git a/examples/dgfip_c/ml_primitif/ml_driver/m.ml b/examples/dgfip_c/ml_primitif/ml_driver/m.ml index 9b39b39b0..dab3cbeca 100644 --- a/examples/dgfip_c/ml_primitif/ml_driver/m.ml +++ b/examples/dgfip_c/ml_primitif/ml_driver/m.ml @@ -17,6 +17,7 @@ let calcul_primitif_isf tgv = exec_ench "calcul_primitif_isf" tgv let calcul_primitif_taux tgv = exec_ench "calcul_primitif_taux" tgv let calcul_correctif tgv = exec_ench "calcul_correctif" tgv +let sauve_base_primitive_penalisee tgv = exec_ench "sauve_base_primitive_penalisee" tgv let sauve_base_initial tgv = exec_ench "sauve_base_initial" tgv let sauve_base_1728 tgv = exec_ench "sauve_base_1728" tgv let sauve_base_anterieure_cor tgv = exec_ench "sauve_base_anterieure_cor" tgv diff --git a/examples/dgfip_c/ml_primitif/ml_driver/stubs.c b/examples/dgfip_c/ml_primitif/ml_driver/stubs.c index 0dddaf333..4fa9e9f87 100644 --- a/examples/dgfip_c/ml_primitif/ml_driver/stubs.c +++ b/examples/dgfip_c/ml_primitif/ml_driver/stubs.c @@ -76,6 +76,7 @@ static ench_t enchaineurs[] = { { "calcul_primitif_taux", calcul_primitif_taux }, { "calcul_correctif", calcul_correctif }, + { "sauve_base_primitive_penalisee", sauve_base_primitive_penalisee }, { "sauve_base_initial", sauve_base_initial }, { "sauve_base_1728", sauve_base_1728 }, { "sauve_base_anterieure_cor", sauve_base_anterieure_cor }, diff --git a/examples/dgfip_c/ml_primitif/static/const.h b/examples/dgfip_c/ml_primitif/static/const.h index 1a3c67176..f4c9f3296 100644 --- a/examples/dgfip_c/ml_primitif/static/const.h +++ b/examples/dgfip_c/ml_primitif/static/const.h @@ -56,6 +56,8 @@ struct S_irdata #endif /* FLG_COMPACT */ +#define MAX_ANO 4 + #define RESTITUEE 5 #define RESTITUEE_P 6 #define RESTITUEE_C 7 diff --git a/examples/dgfip_c/ml_primitif/static/enchain_static.c.inc b/examples/dgfip_c/ml_primitif/static/enchain_static.c.inc index 276488f7b..6718c4802 100644 --- a/examples/dgfip_c/ml_primitif/static/enchain_static.c.inc +++ b/examples/dgfip_c/ml_primitif/static/enchain_static.c.inc @@ -96,6 +96,7 @@ void free_erreur() static T_discord *discords = 0; static T_discord *tas_discord = 0; static T_discord **p_discord = &discords; +static short nb_bloquantes; static jmp_buf jmp_bloq; static void init_erreur(void) @@ -104,6 +105,7 @@ static void init_erreur(void) tas_discord = discords; discords = 0; p_discord = &discords; + nb_bloquantes = 0; } void add_erreur(T_erreur *erreur, char *code) @@ -125,7 +127,7 @@ void add_erreur(T_erreur *erreur, char *code) p_discord = &new_discord->suivant; if (strcmp(erreur->isisf, "O")) { - if (erreur->type == ANOMALIE) { + if ((erreur->type == ANOMALIE) && (++nb_bloquantes >= MAX_ANO)) { longjmp(jmp_bloq, 1); } } diff --git a/mpp_specs/dgfip_base.mpp b/mpp_specs/dgfip_base.mpp index 8af4334e0..06e1f12b5 100644 --- a/mpp_specs/dgfip_base.mpp +++ b/mpp_specs/dgfip_base.mpp @@ -15,6 +15,9 @@ sauve_base_1728(): X = X # outputs <- call_m_rules(base_1728 corrective) +sauve_base_primitive_penalisee(): + outputs <- call_m_rules(base_primitive_penalisee corrective) + sauve_base_premier(): outputs <- call_m_rules(base_premier corrective) diff --git a/src/mlang/dgfip_m.ml b/src/mlang/dgfip_m.ml index 8e6e9b4d6..997bcd26c 100644 --- a/src/mlang/dgfip_m.ml +++ b/src/mlang/dgfip_m.ml @@ -91,6 +91,9 @@ domaine regle taux domaine regle modul; +domaine regle corrective base_primitive_penalisee +: calculable; + domaine regle corrective base_anterieure_cor : calculable;