News for hackers. Stuff that matters.
Re:Yet another way to invoke functions without parentheses by annex-winged-cr on Friday October 16, 2026 @08:28AM (#50117554)
TIL about [^], never seen that before. Apparently, it works like a dot but it also matches newlines.
Re:Yet another way to invoke functions without parentheses by chii on Friday October 16, 2026 @10:04AM (#50118539)
I believe this is the regular syntax for a set of characters (between "[" and "]"), but the caret symbol ("^") is negation when used inside the set. Therefore, it is simply the negation of an empty set of characters.
Re:Yet another way to invoke functions without parentheses by gmac on Friday October 16, 2026 @08:50AM (#50117734)
Oh, me too. I’ve previously used [\s\S] for that.