-
Notifications
You must be signed in to change notification settings - Fork 73
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
core: add functional-type directive #3517
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very very nice
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3517 +/- ##
==========================================
- Coverage 90.35% 90.31% -0.04%
==========================================
Files 465 465
Lines 58459 58524 +65
Branches 5581 5588 +7
==========================================
+ Hits 52821 52858 +37
- Misses 4207 4235 +28
Partials 1431 1431 ☔ View full report in Codecov by Sentry. |
"test.functional_type %0, %1 : (i32, i32) -> ()", | ||
"%0, %1 = test.functional_type %2, %3 : (i32, i32) -> (i32, i32)", | ||
"%0 = test.functional_type %1 : (i32) -> i32", | ||
"%0 = test.functional_type : () -> i32", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Side note: There's an extra space that gets printed here, which is presumably a bug with one of the operands directives.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be fixed by #3530
c8bc6f7
to
940bc1a
Compare
I've added an extra test to this. This also has given a way to actually trigger |
Adds the functional-type directive, which takes two typeable directives as input.
The key difficulty here was dealing with the results, which are usually surrounded by parentheses but don't have to be if there is exactly one result.
Still a draft as this needs more tests, also stacked on #3516.