From 516277221cfc45026f24b25e3a124ad9b97658a3 Mon Sep 17 00:00:00 2001 From: Dirk Ziegelmeier Date: Thu, 22 Aug 2024 09:46:36 +0200 Subject: [PATCH] Convert messages to error messages --- generator/src/generator/Transformations.egl | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/generator/src/generator/Transformations.egl b/generator/src/generator/Transformations.egl index f1f7225..69facd7 100644 --- a/generator/src/generator/Transformations.egl +++ b/generator/src/generator/Transformations.egl @@ -59,7 +59,7 @@ operation Tuple regionTransform(statemachine : Tuple, parent_state : Tuple) { // Initial variable name var initial = statemachine.all_states.get(self.initial_state_id); if (initial == null) { - ("Unable to find state id " + self.initial_state_id).println(); + ("Unable to find state id " + self.initial_state_id).errln(); } self.initial_variable_name = initial.variable_name; } @@ -67,7 +67,7 @@ operation Tuple regionTransform(statemachine : Tuple, parent_state : Tuple) { operation Tuple stateTransform(statemachine : Tuple, region : Tuple, parent_state : Tuple) { self.transitions_for_trigger_transformed = new Map(); if ((self.region == null) and self.transitions_for_trigger.isEmpty()) { - (statemachine.name + ": No outgoing transitions from state " + self.name).println(); + (statemachine.name + ": No outgoing transitions from state " + self.name).errln(); } // State type @@ -84,7 +84,7 @@ operation Tuple stateTransform(statemachine : Tuple, region : Tuple, parent_stat self.entry_pointer = "nullptr"; if (self.entry.isDefined()) { if (self.entry == "") { - (sm.name + ": Empty entry function in state " + self.name).println(); + (sm.name + ": Empty entry function in state " + self.name).errln(); } self.entry_pointer = "&" + statemachine.name + "::" + "Impl::" + self.entry; if (not statemachine.all_entry_exit.includes(self.entry)) { @@ -96,7 +96,7 @@ operation Tuple stateTransform(statemachine : Tuple, region : Tuple, parent_stat self.exit_pointer = "nullptr"; if (self.exit.isDefined()) { if (self.exit == "") { - (sm.name + ": Empty exit function in state " + self.name).println(); + (sm.name + ": Empty exit function in state " + self.name).errln(); } self.exit_pointer = "&" + statemachine.name + "::" + "Impl::" + self.exit; if (not statemachine.all_entry_exit.includes(self.exit)) { @@ -139,7 +139,7 @@ operation Tuple stateTransform(statemachine : Tuple, region : Tuple, parent_stat } } if (transitions.trans_unconditional.size() > 1) { - ("More than one unconditional outgoing transition from state " + self.name + " for trigger " + trigger).println(); + ("More than one unconditional outgoing transition from state " + self.name + " for trigger " + trigger).errln(); } self.transitions_for_trigger_transformed.put(trigger, transitions); @@ -159,7 +159,7 @@ operation Tuple transitionTransform(statemachine : Tuple, state : Tuple, trigger all_actions.add("&" + statemachine.name + "::" + statemachine.impl_type + "::" + action); if (not statemachine.all_actions.includes(action)) { if (action == "") { - (sm.name + ": Empty function behavior in transition starting from state " + self.start).println(); + (sm.name + ": Empty function behavior in transition starting from state " + self.start).errln(); } statemachine.all_actions.add(action); } @@ -185,7 +185,7 @@ operation Tuple transitionTransform(statemachine : Tuple, state : Tuple, trigger if(not self.internal and (self.target_state_id != null)) { var target = statemachine.all_states.get(self.target_state_id); if (target == null) { - ("Unable to find state id " + self.target_state_id).println(); + ("Unable to find state id " + self.target_state_id).errln(); } self.target_variable_name = target.variable_name; @@ -207,7 +207,7 @@ operation Tuple transitionTransform(statemachine : Tuple, state : Tuple, trigger } } if (self.trans_unconditional.size() > 1) { - ("More than one unconditional outgoing transition from state " + self.name + " for trigger " + trigger).println(); + ("More than one unconditional outgoing transition from state " + state.name + " for trigger " + trigger).errln(); } } %] \ No newline at end of file