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

Inconsistency between AND and OR ReqlExpr methods #36

Closed
quentez opened this issue Mar 20, 2016 · 2 comments
Closed

Inconsistency between AND and OR ReqlExpr methods #36

quentez opened this issue Mar 20, 2016 · 2 comments

Comments

@quentez
Copy link

quentez commented Mar 20, 2016

At the moment, the signature for Or() on a ReqlExpr is:

Or(object exprA, params object[] exprs)

And for And():

And(params object[] exprs)

Not only would it be more consistent to have Or() behave like And(), it would also make it easier to build these kinds of expressions dynamically from a collection of items.

@bchavez
Copy link
Owner

bchavez commented Mar 20, 2016

Hi @quentez ,

Thanks for bringing up the issue, I appreciate it. You raise an interesting issue. As far as I can tell, I don't immediately see a reason the signatures for And and Or to be different. Although the Java driver has similar method signatures:

Java Driver: ReqlExpr.java

    public Or or(Object exprA, Object... exprs) {
      ....
    }
    public And and(Object... exprs) {
      ....
    }

At least for now, there isn't anything I can do until I can get another set of eyes to look at the method signatures in the Java source. I think this needs to be investigated further upstream in Java Driver since our C# AST is sourced from the Java Driver's metadata.

ping: @deontologician

PS. I was just made aware that Josh is currently on vacation. He wont be back until the end of next week.

@quentez
Copy link
Author

quentez commented Apr 5, 2016

Thanks for the quick fix :) !

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