Skip to content

feat: allow arrayAttr parsing in constraint #510

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

mathmer-amd
Copy link

In PDLL the syntax let array = ["attr1", "attr2"]; is only usable in rewrite section, but not in constraint section of a pattern.
This PR add the parsing of this syntax also in the constraint section of a pattern.

Also, the empty array [] was considered as a parsing error, this PR fix this little parsing issue.

Verified

This commit was signed with the committer’s verified signature.
BiagioFesta Biagio Festa
Copy link

@jorickert jorickert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍
As @ttjost added the original addElemToArrayAttr builtin, I am interested in what was his reason to restrict it to the rewrite section

Verified

This commit was signed with the committer’s verified signature.
BiagioFesta Biagio Festa
Copy link
Collaborator

@mgehre-amd mgehre-amd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

@mathmer-amd mathmer-amd merged commit 40e3dd2 into feature/fused-ops Mar 20, 2025
4 checks passed
@mathmer-amd mathmer-amd deleted the mmerienn.pdll_allow_parsing_of_arrayAttr_in_constraints branch March 20, 2025 16:16
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.

None yet

4 participants