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

Make condition operators extendable #4

Closed
myguidingstar opened this issue Feb 21, 2018 · 1 comment
Closed

Make condition operators extendable #4

myguidingstar opened this issue Feb 21, 2018 · 1 comment

Comments

@myguidingstar
Copy link
Contributor

Currently operators must be one of =, >, < etc. Users should be able to add their own operators, too

@myguidingstar
Copy link
Contributor Author

myguidingstar commented Feb 22, 2018

Should be implemented with some multimethods:
(operator-keyword? :custom-keyword) => true (default to false)
(parameter-count :custom-keyword) => number? or :any

(condition-statement "`table`.`column`" :custom-keyword [:arg-1 :arg-2])

=>

 ["`table`.`column` MY-OPERATOR (?, ?)" [:arg-1 :arg-2]]

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

1 participant