Skip to content
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

Report duplicate rules as errors #318

Closed
dmajda opened this issue Feb 13, 2015 · 1 comment
Closed

Report duplicate rules as errors #318

dmajda opened this issue Feb 13, 2015 · 1 comment
Labels
Milestone

Comments

@dmajda
Copy link
Contributor

dmajda commented Feb 13, 2015

PEG.js currently allows duplicate rule definitions and applies “last one wins” semantics for these. It should report an error instead. The reason is that a duplicate rule definition is most likely unintended and a result of user error.

@dmajda dmajda added this to the 0.9.0 milestone Feb 13, 2015
@dmajda dmajda added the feature label Feb 13, 2015
futagoza added a commit to futagoza/pegjs that referenced this issue Feb 22, 2015
- can be disabled by option `{ reportDuplicateRules: false }`
- resolves pegjs#318
@futagoza
Copy link
Member

@dmajda: I have fixed the issue in #322

futagoza added a commit to futagoza/pegjs that referenced this issue Apr 2, 2015
@dmajda dmajda mentioned this issue Apr 3, 2015
@dmajda dmajda modified the milestones: 0.10.0, 0.9.0 Aug 14, 2015
@dmajda dmajda changed the title Make duplicate rules an error Report duplicate rules as errors Sep 11, 2015
Mingun added a commit to Mingun/pegjs that referenced this issue Jan 3, 2016
- Issue pegjs#318: report rules, that redefined by other rules with same name
- Issue pegjs#200: report rules, than not used anymore.
Mingun added a commit to Mingun/pegjs that referenced this issue Jan 3, 2016
@dmajda dmajda closed this as completed in eb5875b Jun 22, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants