Permalink
Browse files

fixed a bug that's been there for a really long time, but didn't seem…

… to be causing any problems (expr4 takes an argument that tells it whether or not it's ok to accept an empty expression, but OMetaParser's rulePart rule was not passing that argument to expr4)
  • Loading branch information...
alexwarth committed Aug 5, 2011
1 parent bbe298d commit 07067b144d86f4bd08d352b3646abd3030e10c04
Showing with 4 additions and 4 deletions.
  1. +1 −1 bs-ometa-compiler.js
  2. +3 −3 bs-ometa-compiler.txt
View

Some generated files are not rendered by default. Learn more.

Oops, something went wrong.
View
@@ -68,9 +68,9 @@ ometa BSOMetaParser {
rule = &(ruleName:n) !(this.locals = {'$elf=this': true, '_fromIdx=this.input.idx': true})
rulePart(n):x ("," rulePart(n))*:xs -> [#Rule, n, ownPropertyNames(this.locals),
[#Or, x].concat(xs)],
- rulePart :rn = ruleName:n ?(n == rn) expr4:b1 ( "=" expr:b2 -> [#And, b1, b2]
- | empty -> b1
- ),
+ rulePart :rn = ruleName:n ?(n == rn) expr4(false):b1 ( "=" expr:b2 -> [#And, b1, b2]
+ | empty -> b1
+ ),
grammar = keyword('ometa') name:n
( "<:" name | empty -> 'OMeta' ):sn
"{" listOf(#rule, ','):rs "}" BSOMetaOptimizer.optimizeGrammar(

0 comments on commit 07067b1

Please sign in to comment.