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
Currently, our naming convention rules only allow for a single regex that identifies what is permitted/valid.
It would be nice to add an additional forbidden regex to identify things that are not valid, like function names starting with do_.
For semantics purposes, a forbidden keyword might make sense... but then you'd always have to have an order in evaluation: if you accept and negate a given string, which one is valid?
Have you considered negative lookaheads, like ^(?!(^do_)).*$?
HA! I didn't know about negative lookaheads.
I still think that a forbidden regex would be clearer and the usual semantics is "allow everything that matches with regexexcept if it matches forbidden regex". I would go with that, with the default for forbidden being none.
Currently, our naming convention rules only allow for a single regex that identifies what is permitted/valid.
It would be nice to add an additional forbidden regex to identify things that are not valid, like function names starting with
do_
.Ref: WhatsApp/erlfmt#91
The text was updated successfully, but these errors were encountered: