Skip to content

Gate MVP example conflicts with BNF #480

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

Closed
mkatychev opened this issue Mar 25, 2025 · 1 comment
Closed

Gate MVP example conflicts with BNF #480

mkatychev opened this issue Mar 25, 2025 · 1 comment

Comments

@mkatychev
Copy link
Contributor

The feature gate example lists a gate as having both a version and feature field: @since(version = 0.2.2, feature = fancy-foo)
https://github.com/WebAssembly/component-model/blob/main/design/mvp/WIT.md#feature-gates

However the BNF for gate syntax lists feature-field as only being used by an @unstable gate:

gate ::= gate-item*
gate-item ::= unstable-gate
            | since-gate
            | deprecated-gate

unstable-gate ::= '@unstable' '(' feature-field ')'
since-gate ::= '@since' '(' version-field ')'
deprecated-gate ::= '@deprecated' '(' version-field ')'

feature-field ::= 'feature' '=' id
version-field ::= 'version' '=' <valid semver>
@lukewagner
Copy link
Member

(Sorry for the slow reply! I was out the last 2 weeks.). Thanks for the careful read and good catch! If I'm recalling history correctly, we started by allowing @since to have both a version and feature-name, and then removed the latter in #387, but we forgot to update this example. I'll fix the example shortly.

lukewagner added a commit that referenced this issue Apr 7, 2025
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

No branches or pull requests

2 participants