infobloxopen / seal

Apache License 2.0
16 stars 11 forks source link

#79 allow `=~` as OP_MATCHES operator in where clause conditionals #100

Closed abynenkov-ib closed 4 years ago

rchowinfoblox commented 4 years ago

Alexey you're gonna hate this, but I realized I recalled the wrong token for regexp operator in perl: it's =~ (and !~), not ~=. If it's possible I think we should change to =~ as that's what most people are used to. @wplu should we also support !~ for negated regexp matching?

wplu commented 4 years ago

yes, please change it - i have changed the desc in the issue

wplu commented 4 years ago

we'll support !~ in a different issue if needed.

isn't !~ the same as not re_match(...)? if so where not subject.jti =~ "@petstore.com$" should suffice, right?

abynenkov-ib commented 4 years ago

Done, but ~= seems better to me And I agree with Phil, !~ (not match) is not needed, because it's possible to use not operator in seal