Skip to content

fix: scope element expression walk to dotted property containers only (OOM) - #5

Merged
cprima merged 1 commit into
mainfrom
fix/expr-element-scope-oom
Mar 10, 2026
Merged

cprima merged 1 commit into
mainfrom
fix/expr-element-scope-oom

Conversation

@cprima

@cprima cprima commented Mar 10, 2026

Copy link
Copy Markdown
Contributor

Fixes OOM crash introduced in 0.1.2.

element.iter() on container activities (Sequence, If, etc.) walked ALL descendant activities, causing quadratic expression accumulation — expressions from child activities collected by the parent, then again by each child.

Fix: only descend into direct children whose local tag contains a dot (e.g. Assign.To, InvokeMethod.Parameters). These are property containers, not child activities, and are the only valid nesting locations for VisualBasicValue elements.

  • All 86 unit tests pass
  • No change to observable behaviour for correct Syntax B XAML

Fixes OOM crash: element.iter() on container activities (Sequence, If, etc.)
walked all descendant activities, causing quadratic expression accumulation.
Now only descends into dotted property children (Assign.To, InvokeMethod.Parameters)
which is where VisualBasicValue elements legitimately appear.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@cprima
cprima merged commit b0818b5 into main Mar 10, 2026
0 of 6 checks passed
@cprima
cprima deleted the fix/expr-element-scope-oom branch March 10, 2026 10:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant