Share validation code between constant expressions and function bodie…#1783
Merged
Conversation
8ddf70c to
73c8d3f
Compare
ngzhian
approved these changes
Dec 10, 2021
ngzhian
left a comment
Member
There was a problem hiding this comment.
The failure messages are less clear i think (previously it mentions global initializer expression, now it's constant expression), but with the line and column it should be easy to pinpoint the errors.
Member
Author
I agree, it could be seen a less clear, but its also more consistent which I like. I can take a look and see if we can be more specific perhaps. |
73c8d3f to
92f1578
Compare
…s. NFC Previously we has special cases for initializer expressions (constant expressions). This change paves the way for adding support for extended constant expressions that support a wider range of instructions. This change removes twice as many lines as it adds which shows that this simplification is probably worthwhile even without the pending extensions.
92f1578 to
ab9f0e2
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…s. NFC
Previously we has special cases for initializer expressions (constant
expressions). This change paves the way for adding support for
extended constant expressions that support a wider range of
instructions.
This change removes twice as many lines as it adds which shows that
this simplification is probably worthwhile even without the pending
extensions.