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

Add/Sub error in QLParser.rats? #2

Open
LE-Blythe opened this issue Jan 10, 2013 · 1 comment
Open

Add/Sub error in QLParser.rats? #2

LE-Blythe opened this issue Jan 10, 2013 · 1 comment

Comments

@LE-Blythe
Copy link

constant Action<Expr> AddTail = 
    "+" Spacing right:MulExpr { 
        yyValue = new Action<Expr>() {
            public Expr run(Expr left) {
              return new Add(left, right);
            }
        };
    }
    / "-" Spacing right:MulExpr { 
        yyValue = new Action<Expr>() {
            public Expr run(Expr left) {
              return new Add(left, right);
            }
        };
    }; 

I think that 2nd Add(left, right) should be Sub(left, right).
Is that right?

@tvdstorm
Copy link
Contributor

Asking the question is answering it :)

Proof that you should never copy-paste code.

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