889
what debugging regex feels like
(lemmy.ml)
awk-ward
I think he found the Road Runner.
Elisp has a nice notation for maintainably composing regexes like any other programming expression.
Only language I've seen offer that.
So instead of "/\\*\\(?:[^*]\\|\\*[^/]\\)*\\*+/"
, the regular expression to match C block comments could be expressed (with inline comments)
(rx "/*" ; Initial /*
(zero-or-more
(or (not (any "*")) ; Either non-*,
(seq "*" ; or * followed by
(not (any "/"))))) ; non-/
(one-or-more "*") ; At least one star,
"/") ; and the final /
Ffs just rewrite it
This would honestly be a lot easier
I don't know any hieroglyphs, but I do know cuneiform. Would rather read cuneiform than regex!
Welcome to Programmer Humor!
This is a place where you can post jokes, memes, humor, etc. related to programming!
For sharing awful code theres also Programming Horror.