From 52ee1162b11d626e42f60dab13ca9333c6c69be3 Mon Sep 17 00:00:00 2001 From: Nick Battle Date: Wed, 10 Apr 2024 17:59:10 +0100 Subject: [PATCH] Slightly better validationError printing --- fmi2/rule-model/Validation.vdmsl | 4 ++-- fmi3/rule-model/Validation.vdmsl | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/fmi2/rule-model/Validation.vdmsl b/fmi2/rule-model/Validation.vdmsl index 03a7651..0e2c404 100644 --- a/fmi2/rule-model/Validation.vdmsl +++ b/fmi2/rule-model/Validation.vdmsl @@ -34,7 +34,7 @@ functions isValidFMIConfiguration: FmiModelDescription | FmiBuildDescription | FmiTerminalsAndIcons +> bool isValidFMIConfiguration(conf) == if validationError <> nil - then /* @Printf("%s\n", validationError) */ false + then /* @Printf("%#s\n", validationError) */ false elseif is_(conf, FmiModelDescription) then inv_FmiModelDescription'(conf) @@ -54,7 +54,7 @@ functions isValidFMIConfigurations: [FmiModelDescription] * [FmiBuildDescription] * [FmiTerminalsAndIcons] +> bool isValidFMIConfigurations(model, build, terminals) == allOf ([ - validationError <> nil => /* @Printf("%s\n", validationError) */ false, + validationError <> nil => /* @Printf("%#s\n", validationError) */ false, model <> nil => inv_FmiModelDescription'(model), build <> nil => inv_FmiBuildDescription'(build), diff --git a/fmi3/rule-model/Validation.vdmsl b/fmi3/rule-model/Validation.vdmsl index f36e0dd..17b50dc 100644 --- a/fmi3/rule-model/Validation.vdmsl +++ b/fmi3/rule-model/Validation.vdmsl @@ -34,7 +34,7 @@ functions isValidFMIConfiguration: FmiModelDescription | FmiBuildDescription | FmiTerminalsAndIcons +> bool isValidFMIConfiguration(conf) == if validationError <> nil - then /* @Printf("%s\n", validationError) */ false + then /* @Printf("%#s\n", validationError) */ false elseif is_(conf, FmiModelDescription) then inv_FmiModelDescription'(conf) @@ -54,7 +54,7 @@ functions isValidFMIConfigurations: [FmiModelDescription] * [FmiBuildDescription] * [FmiTerminalsAndIcons] +> bool isValidFMIConfigurations(model, build, terminals) == allOf ([ - validationError <> nil => /* @Printf("%s\n", validationError) */ false, + validationError <> nil => /* @Printf("%#s\n", validationError) */ false, model <> nil => inv_FmiModelDescription'(model), build <> nil => inv_FmiBuildDescription'(build),