You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Feature]: Textual Notation Scoped suppression of a keyword the current rule already implies #362
I have verified that I am running the latest version of the SysML2.NET
I have searched open and closed issues to ensure it has not already been reported
Description
Message : FlowUsage = OccurrenceUsagePrefix 'message' MessageDeclaration DefinitionBody { isAbstract = true } — the message keyword sets isAbstract, but RefPrefix's isAbstract ?= 'abstract' emits it again, giving abstract message x of P[1];. Valid and
same AST as the pilot's message x of P[1];, so cosmetic only.
Add a per-element scope on TextualNotationWriterContext, mirroring SuspendOperatorContext:
Back it with a Dictionary<(Guid, string), int> counter, not a HashSet — a nested re-open must not have its inner dispose clear the outer suppression. Per-context state, never static.
Generator: emit the using in the rule emitter and consult it in the ?= conditional built at RuleProcessor.cs:531-547.
Two constraints, both load-bearing:
Hoist the scope. NonParsingAssignmentElement is processed in element order (RuleProcessor.ElementProcessing.cs:261) and the action is the last element of Message while the prefix is the first. Pre-scan the rule's elements and open above element 0.
Consult it only at ?= sites. Suppress only when the action sets P to V and a P ?= 'kw' token triggers on the same V. MultiplicityPart carries { isUnique = false } and emits nonunique from if (!poco.IsUnique) — same property, opposite polarity. A blanket rule deletes nonunique from 6 lines of folder 14's locked baseline.
Only one site fires today (isAbstract/Message); the other 13 action assignments in both grammars are inert. Blast radius on locked folders is zero.
Activity