Skip to content

Remove DSLNode-based implementation#857

Merged
natecook1000 merged 2 commits intomainfrom
remove-old-dslnode
Apr 15, 2026
Merged

Remove DSLNode-based implementation#857
natecook1000 merged 2 commits intomainfrom
remove-old-dslnode

Conversation

@natecook1000
Copy link
Copy Markdown
Member

The recursive DSLTree approach required nodes nested in nodes. The DSLTree implementation flattened this tree, but didn't remove the nested nodes, instead replacing them with placeholder entries that were unused, in order to reduce the code change. This change completes the transition, modifying the nodes to no longer store their children.

With this change, we can also eliminate the indirection in the nodes, and remove a significant amount of unused code. The change includes some expanded test coverage of the RegexBuilder syntax conversion, as well.

@natecook1000 natecook1000 force-pushed the remove-old-dslnode branch 2 times, most recently from a9693f6 to 4ca54ce Compare April 10, 2026 04:25
@natecook1000
Copy link
Copy Markdown
Member Author

@swift-ci Please test Linux platform

The recursive DSLTree approach required nodes nested in nodes.
The DSLTree implementation flattened this tree, but didn't remove
the nested nodes, instead replacing them with placeholder entries
that were unused, in order to reduce the code change. This
change completes the transition, modifying the nodes to no
longer store their children.

With this change, we can also remove a significant amount of
unused code. The change includes some expanded test coverage
of the RegexBuilder syntax conversion, as well.

Note that even though `DSLTree.Node` no longer requires
declaration as `indirect`, compilation times are worsened
if we remove the indirection.
@parkera
Copy link
Copy Markdown

parkera commented Apr 15, 2026

@swift-ci test

This restores the original scalar spelling of literal patterns
when converting to RegexBuilder syntax.
@natecook1000
Copy link
Copy Markdown
Member Author

@swift-ci Please test Linux platform

@natecook1000 natecook1000 merged commit b8c8a42 into main Apr 15, 2026
23 checks passed
@natecook1000 natecook1000 deleted the remove-old-dslnode branch April 15, 2026 22:41
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.

3 participants