We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
LeftAssociative
Is possible to create a more friendly overload?
Actual:
var equal = Terms.Text("=").Or(Terms.Text("==")); var notEqual = Terms.Text("<>").Or(Terms.Text("!=")); var equality = relational.LeftAssociative( (equal, static (a, b) => new BinaryExpression(BinaryExpressionType.Equal, a, b)), (notEqual, static (a, b) => new BinaryExpression(BinaryExpressionType.NotEqual, a, b)) );
Suggestion:
var equal = Terms.Text("=").Or(Terms.Text("==")).Then(_=>BinaryExpressionType.Equal); var notEqual = Terms.Text("<>").Or(Terms.Text("!=")).Then(_=>BinaryExpressionType.NotEqual); var equality = relational.LeftAssociative([equal, notEqual], (a,b, operation)=>{ return new BinaryExpression(operation, a, b); });
The text was updated successfully, but these errors were encountered:
It's something that could be added, looks nice for your case. Feel free to submit a PR with a test.
Sorry, something went wrong.
Successfully merging a pull request may close this issue.
Is possible to create a more friendly overload?
Actual:
Suggestion:
The text was updated successfully, but these errors were encountered: