From fe3a83d8c83daa1bc43db222035ecb97a1db0678 Mon Sep 17 00:00:00 2001 From: HOS Date: Fri, 7 Nov 2025 16:09:28 +0100 Subject: [PATCH 01/10] Start --- RationaleMCP/Changes/37/semantic/3610.md | 50 ++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 RationaleMCP/Changes/37/semantic/3610.md diff --git a/RationaleMCP/Changes/37/semantic/3610.md b/RationaleMCP/Changes/37/semantic/3610.md new file mode 100644 index 000000000..039c9e664 --- /dev/null +++ b/RationaleMCP/Changes/37/semantic/3610.md @@ -0,0 +1,50 @@ +\#3610 Discrete-time variability based on GenerateEvents + + + +Main change + +Variability of functions with GenerateEvents. + + + +Reason + +Making it possible to create functions that generate events similarly as the built-in functions, and have rules consistent with them just being inlined. + + + +Breaks + +``` + +  function foo + +  input Real x; + +  output Integer i=bar(x)+(if x>0 then 1 else 0); + +  annotation(GenerateEvents=true); + +  end foo; + + + +  function bar + +  input Real x; + +  output Integer i=integer(x); + +  annotation(GenerateEvents=false); + +  end bar; + +  Integer x=foo(time); + +``` + +The call of bar in foo is now illegal, similarly as in a model. + + + From 11f0af4fdf44a885062db915f52a8506b67e7ef9 Mon Sep 17 00:00:00 2001 From: HOS Date: Fri, 7 Nov 2025 16:16:23 +0100 Subject: [PATCH 02/10] Description --- RationaleMCP/Changes/37/semantic/3610.md | 50 ------------------------ RationaleMCP/Changes/Readme.md | 8 ++++ 2 files changed, 8 insertions(+), 50 deletions(-) delete mode 100644 RationaleMCP/Changes/37/semantic/3610.md create mode 100644 RationaleMCP/Changes/Readme.md diff --git a/RationaleMCP/Changes/37/semantic/3610.md b/RationaleMCP/Changes/37/semantic/3610.md deleted file mode 100644 index 039c9e664..000000000 --- a/RationaleMCP/Changes/37/semantic/3610.md +++ /dev/null @@ -1,50 +0,0 @@ -\#3610 Discrete-time variability based on GenerateEvents - - - -Main change - -Variability of functions with GenerateEvents. - - - -Reason - -Making it possible to create functions that generate events similarly as the built-in functions, and have rules consistent with them just being inlined. - - - -Breaks - -``` - -  function foo - -  input Real x; - -  output Integer i=bar(x)+(if x>0 then 1 else 0); - -  annotation(GenerateEvents=true); - -  end foo; - - - -  function bar - -  input Real x; - -  output Integer i=integer(x); - -  annotation(GenerateEvents=false); - -  end bar; - -  Integer x=foo(time); - -``` - -The call of bar in foo is now illegal, similarly as in a model. - - - diff --git a/RationaleMCP/Changes/Readme.md b/RationaleMCP/Changes/Readme.md new file mode 100644 index 000000000..0f723df55 --- /dev/null +++ b/RationaleMCP/Changes/Readme.md @@ -0,0 +1,8 @@ +This list the semantic changes in the various versions. + +Clarifications, examples, reformulations, and changes in layout or other external resources will not be included in this list. + + + +The are separate files for each release to make it easy to maintain during development, but may later be merged. + From c42d8948c1b207cd8327ca23adcd572ec7cf6c3e Mon Sep 17 00:00:00 2001 From: HOS Date: Fri, 7 Nov 2025 16:17:17 +0100 Subject: [PATCH 03/10] Description --- RationaleMCP/Changes/37/3610.md | 50 +++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 RationaleMCP/Changes/37/3610.md diff --git a/RationaleMCP/Changes/37/3610.md b/RationaleMCP/Changes/37/3610.md new file mode 100644 index 000000000..039c9e664 --- /dev/null +++ b/RationaleMCP/Changes/37/3610.md @@ -0,0 +1,50 @@ +\#3610 Discrete-time variability based on GenerateEvents + + + +Main change + +Variability of functions with GenerateEvents. + + + +Reason + +Making it possible to create functions that generate events similarly as the built-in functions, and have rules consistent with them just being inlined. + + + +Breaks + +``` + +  function foo + +  input Real x; + +  output Integer i=bar(x)+(if x>0 then 1 else 0); + +  annotation(GenerateEvents=true); + +  end foo; + + + +  function bar + +  input Real x; + +  output Integer i=integer(x); + +  annotation(GenerateEvents=false); + +  end bar; + +  Integer x=foo(time); + +``` + +The call of bar in foo is now illegal, similarly as in a model. + + + From 50afc49040c328601acdff63d2d1e7295f3a69f6 Mon Sep 17 00:00:00 2001 From: Hans Olsson Date: Fri, 7 Nov 2025 16:20:11 +0100 Subject: [PATCH 04/10] Update 3610.md Cleanup --- RationaleMCP/Changes/37/3610.md | 60 +++++++++++---------------------- 1 file changed, 19 insertions(+), 41 deletions(-) diff --git a/RationaleMCP/Changes/37/3610.md b/RationaleMCP/Changes/37/3610.md index 039c9e664..3ae5aca1e 100644 --- a/RationaleMCP/Changes/37/3610.md +++ b/RationaleMCP/Changes/37/3610.md @@ -1,50 +1,28 @@ -\#3610 Discrete-time variability based on GenerateEvents +Discrete-time variability based on GenerateEvents #3610 - - -Main change +# Main change Variability of functions with GenerateEvents. - - -Reason +# Reason Making it possible to create functions that generate events similarly as the built-in functions, and have rules consistent with them just being inlined. - - -Breaks - +# Breaks + +``` modelica +function foo + input Real x; + output Integer i=bar(x)+(if x>0 then 1 else 0); + annotation(GenerateEvents=true); +end foo; + +function bar + input Real x; + output Integer i=integer(x); + annotation(GenerateEvents=false); +end bar; +Integer x=foo(time); ``` -  function foo - -  input Real x; - -  output Integer i=bar(x)+(if x>0 then 1 else 0); - -  annotation(GenerateEvents=true); - -  end foo; - - - -  function bar - -  input Real x; - -  output Integer i=integer(x); - -  annotation(GenerateEvents=false); - -  end bar; - -  Integer x=foo(time); - -``` - -The call of bar in foo is now illegal, similarly as in a model. - - - +The call of `bar` in `foo` is now illegal, similarly as in a model. From f1024700137c6e98ee90d4d253e73971fbfc3f60 Mon Sep 17 00:00:00 2001 From: HOS Date: Tue, 11 Nov 2025 16:51:34 +0100 Subject: [PATCH 05/10] MajorMinor --- RationaleMCP/Changes/{37 => 3_7}/3610.md | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename RationaleMCP/Changes/{37 => 3_7}/3610.md (100%) diff --git a/RationaleMCP/Changes/37/3610.md b/RationaleMCP/Changes/3_7/3610.md similarity index 100% rename from RationaleMCP/Changes/37/3610.md rename to RationaleMCP/Changes/3_7/3610.md From 6af500363513aeed00f3f6a51f1a809ba8f7f504 Mon Sep 17 00:00:00 2001 From: Hans Olsson Date: Wed, 19 Nov 2025 16:51:42 +0100 Subject: [PATCH 06/10] Apply suggestions from code review Co-authored-by: Henrik Tidefelt --- RationaleMCP/Changes/Readme.md | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/RationaleMCP/Changes/Readme.md b/RationaleMCP/Changes/Readme.md index 0f723df55..9693e3332 100644 --- a/RationaleMCP/Changes/Readme.md +++ b/RationaleMCP/Changes/Readme.md @@ -1,8 +1,5 @@ -This list the semantic changes in the various versions. +This directory contains descriptions of semantic changes introduced in the various versions. Clarifications, examples, reformulations, and changes in layout or other external resources will not be included in this list. - - -The are separate files for each release to make it easy to maintain during development, but may later be merged. - +There are separate files for each release to make it easy to maintain during development, but the files may later be merged. From 115c8567e413fd31bd3a992b466d948f5ed8c804 Mon Sep 17 00:00:00 2001 From: Hans Olsson Date: Wed, 19 Nov 2025 16:52:45 +0100 Subject: [PATCH 07/10] Apply suggestions from code review Co-authored-by: Henrik Tidefelt --- RationaleMCP/Changes/3_7/3610.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/RationaleMCP/Changes/3_7/3610.md b/RationaleMCP/Changes/3_7/3610.md index 3ae5aca1e..0cc7e8919 100644 --- a/RationaleMCP/Changes/3_7/3610.md +++ b/RationaleMCP/Changes/3_7/3610.md @@ -1,14 +1,14 @@ -Discrete-time variability based on GenerateEvents #3610 +# Discrete-time variability based on `GenerateEvents` #3610 -# Main change +## Main change -Variability of functions with GenerateEvents. +Variability of functions with `GenerateEvents`. -# Reason +## Reason Making it possible to create functions that generate events similarly as the built-in functions, and have rules consistent with them just being inlined. -# Breaks +## Breaks ``` modelica function foo From f72675ee91f29f3cb9b04a1abb3e5588c3b3a798 Mon Sep 17 00:00:00 2001 From: Hans Olsson Date: Fri, 28 Nov 2025 15:30:49 +0100 Subject: [PATCH 08/10] Update RationaleMCP/Changes/Readme.md --- RationaleMCP/Changes/Readme.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/RationaleMCP/Changes/Readme.md b/RationaleMCP/Changes/Readme.md index 9693e3332..b6ceb359b 100644 --- a/RationaleMCP/Changes/Readme.md +++ b/RationaleMCP/Changes/Readme.md @@ -1,5 +1,5 @@ -This directory contains descriptions of semantic changes introduced in the various versions. +This directory contains descriptions of semantic changes, particularly backwards incompatible changes, introduced in the various versions. -Clarifications, examples, reformulations, and changes in layout or other external resources will not be included in this list. +Clarifications, new or modified examples, reformulations, and changes in layout or other external resources will not be included in this list. There are separate files for each release to make it easy to maintain during development, but the files may later be merged. From 8719bfd72ee70c68975c5cf82a463768002d3e57 Mon Sep 17 00:00:00 2001 From: Hans Olsson Date: Mon, 1 Dec 2025 09:31:55 +0100 Subject: [PATCH 09/10] Update RationaleMCP/Changes/3_7/3610.md Co-authored-by: Henrik Tidefelt --- RationaleMCP/Changes/3_7/3610.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/RationaleMCP/Changes/3_7/3610.md b/RationaleMCP/Changes/3_7/3610.md index 0cc7e8919..6508ea0f6 100644 --- a/RationaleMCP/Changes/3_7/3610.md +++ b/RationaleMCP/Changes/3_7/3610.md @@ -22,7 +22,8 @@ function bar output Integer i=integer(x); annotation(GenerateEvents=false); end bar; -Integer x=foo(time); + +Real x=foo(time); ``` The call of `bar` in `foo` is now illegal, similarly as in a model. From 0421730fc092c38de5dfb694583ead45f8ea1b04 Mon Sep 17 00:00:00 2001 From: Hans Olsson Date: Mon, 1 Dec 2025 17:45:59 +0100 Subject: [PATCH 10/10] Update RationaleMCP/Changes/3_7/3610.md Co-authored-by: Henrik Tidefelt --- RationaleMCP/Changes/3_7/3610.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/RationaleMCP/Changes/3_7/3610.md b/RationaleMCP/Changes/3_7/3610.md index 6508ea0f6..c76a30b70 100644 --- a/RationaleMCP/Changes/3_7/3610.md +++ b/RationaleMCP/Changes/3_7/3610.md @@ -11,18 +11,18 @@ Making it possible to create functions that generate events similarly as the bui ## Breaks ``` modelica -function foo - input Real x; - output Integer i=bar(x)+(if x>0 then 1 else 0); - annotation(GenerateEvents=true); -end foo; - function bar input Real x; - output Integer i=integer(x); + output Integer i = integer(x); annotation(GenerateEvents=false); end bar; +function foo + input Real x; + output Integer i = bar(x); + annotation(GenerateEvents=true); +end foo; + Real x=foo(time); ```