From 3724507900d2a4503bd5bfb7af20c1c140290c73 Mon Sep 17 00:00:00 2001 From: Henrik Tidefelt Date: Wed, 15 Oct 2025 23:40:46 +0200 Subject: [PATCH 1/2] Fix hyphenation Hyphenated forms are used when going in front of the noun they describe. There are more cases like this that we should return to some other time. --- chapters/functions.tex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chapters/functions.tex b/chapters/functions.tex index f82c478ba..62f59dfe2 100644 --- a/chapters/functions.tex +++ b/chapters/functions.tex @@ -1746,7 +1746,7 @@ \section{Function Inlining and Event Generation}\label{function-inlining-and-eve \begin{semantics} Has only an effect within a function declaration. -By default, {\lstinline!GenerateEvents = false!} and expressions in the function body that would normally be event-generating shall not generate events, similar to inlining the function body while wrapping all expressions in {\lstinline!noEvent!}, see \cref{modelica:noEvent}. +By default, {\lstinline!GenerateEvents = false!} and expressions in the function body that would normally be event generating shall not generate events, similar to inlining the function body while wrapping all expressions in {\lstinline!noEvent!}, see \cref{modelica:noEvent}. By specifying {\lstinline!GenerateEvents = true!}, event-generating expressions in the function body shall generate events as normal, similar to inlining the function body without wrapping all expressions in {\lstinline!noEvent!}. Having {\lstinline!GenerateEvents = true!} implies {\lstinline!Inline = true!} unless overridden by specifying one of the inlining annotations with value {\lstinline!true!} (in particular, {\lstinline!GenerateEvents = true!} cannot be combined with {\lstinline!Inline = false!}). From 6e25c58620c3728d28bb8749a00984d43c791d83 Mon Sep 17 00:00:00 2001 From: Henrik Tidefelt Date: Wed, 15 Oct 2025 23:41:07 +0200 Subject: [PATCH 2/2] Clarify handling of GenerateEvents = true --- chapters/functions.tex | 2 ++ 1 file changed, 2 insertions(+) diff --git a/chapters/functions.tex b/chapters/functions.tex index 62f59dfe2..09c59571b 100644 --- a/chapters/functions.tex +++ b/chapters/functions.tex @@ -1750,6 +1750,8 @@ \section{Function Inlining and Event Generation}\label{function-inlining-and-eve By specifying {\lstinline!GenerateEvents = true!}, event-generating expressions in the function body shall generate events as normal, similar to inlining the function body without wrapping all expressions in {\lstinline!noEvent!}. Having {\lstinline!GenerateEvents = true!} implies {\lstinline!Inline = true!} unless overridden by specifying one of the inlining annotations with value {\lstinline!true!} (in particular, {\lstinline!GenerateEvents = true!} cannot be combined with {\lstinline!Inline = false!}). +A function with \lstinline!GenerateEvents = true! should be considered event generating for purposes of determining where the function may be called, regardless of whether the function body contains any expressions which could actually generate events. + \begin{nonnormative} In case a given inlining annotation proposes to inline at a stage when the tool cannot process {\lstinline!GenerateEvents = true!}, it is recommended to give a diagnostic and instead perform inlining of the function at the nearest stage where {\lstinline!GenerateEvents = true!} can still be respected.