You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have run into a number of cases where a "not matching regex" condition would be useful, i.e. the opposite of =~. Latest example is here: without a "not matching regex" conditional operator, this check cannot use assert() which was specifically designed for cases like this.
Does just have such operator? If not, could it please be added?
BTW I'm not finding the documentation of the assert() function-like expression in the README?
The text was updated successfully, but these errors were encountered:
As of now, "just" does not natively support a "not matching regex" operator directly. However, you can usually achieve a similar effect using existing logical operations. Here’s a common workaround using negation (!) and =~::
Alternatively, the issue might be suggesting a feature request to add a specific !~ or similar operator to make this more intuitive, but this does not seem to be implemented yet.
As for the assert() function, it’s likely being used to validate that certain conditions are true. If you’re not finding it in the documentation, it might be a less-documented feature or related to the specific environment or context the user is working with. Hopefully this helps you.
I think we should add !~. This seems common enough that it's useful, and you can't really work around with negation, since conditionals are a grammar-level hack.
I have run into a number of cases where a "not matching regex" condition would be useful, i.e. the opposite of
=~
. Latest example is here: without a "not matching regex" conditional operator, this check cannot useassert()
which was specifically designed for cases like this.Does
just
have such operator? If not, could it please be added?BTW I'm not finding the documentation of the
assert()
function-like expression in the README?The text was updated successfully, but these errors were encountered: