From 8b4ce3027ee1f71473661b5d6f4ed37b4e2d56bf Mon Sep 17 00:00:00 2001 From: Henrik Tidefelt Date: Tue, 2 Jul 2024 09:11:32 +0200 Subject: [PATCH] Describe lookup atomicity of Base Modelica package --- RationaleMCP/0031/differences.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/RationaleMCP/0031/differences.md b/RationaleMCP/0031/differences.md index c81a5da47..d69c3921f 100644 --- a/RationaleMCP/0031/differences.md +++ b/RationaleMCP/0031/differences.md @@ -10,6 +10,10 @@ The definitions before the `model` either define types or global constants. ## Lexical scoping and record definitions +For purposes of lookup, a Base Modelica package shall be handled as a top-level Modelica package: +- During the lookup process, if an identifier is not found within the Base Modelica package, it must refer to a Base Modelica built-in entity. +- Global name lookup of `.x` (or `.x.y.z`) requires `x` to be a built-in or the name of the Base Modelica package. + Lookup in Base Modelica is significantly simplified compared to full Modelica due to the restricted top level structure of a Base Modelica program, but there are two more restrictions on top of that explained in this section. Taken together, the two restrictions can be summarized concisely as follows: