regex again

Started by cormullion, October 12, 2007, 01:21:56 PM

Previous topic - Next topic

Jeff

#15
Syntax should be as clear as possible.  Some algorithms cannot be expressed simply, because they are not simple algorithms.
Jeff

=====

Old programmers don\'t die. They just parse on...



http://artfulcode.net\">Artful code

jrh

#16
Quote from: "HPW"
Paste it in RegexBuddy and let explain it:


I would have to get a M$ Windoze system in order to do that.  That seems like going from bad to worse!  ;-)

cormullion

#17
That's neat, HP - almost makes it look sensible...!



There are indeed plenty of nitwits who write stuff like that - I just wanted some shortcuts to avoid having to be one of them!

jrh

#18
Quote from: "Jeff snipilly"Syntax should be as clear as possible.  Some algorithms cannot be expressed simply, because they are not simple algorithms.


They can however be broken up into simpler pieces, it's called modular programming.  Regexes suck because they 1) don't do that and 2) use such terse symbols that one need constantly double escape stuff in order to accomplish the string search.



Hello... we're not using 115 baud teletype machines any longer.  The apparent need for robots to decode regex expressions proves that the Perl and regex coders of complex expressions aren't clever, they are nitwits.

rickyboy

#19
Quote from: "jrh"Only a nitwit would write something like that or spend time figuring out what it did.

Ha, ha, ha, ha!  Good one.


Quote from: "jrh"Clear, concise, and simple is what I strive for.  Complexity for its own sake is horse shit.

Am I the only one who noticed that you emphasized *clear*?  I quite agree with you here, and in precisely the order you listed the characteristics.  Simplicity in expression is usually gotten to automatically after one strives first for clarity and economy.
(λx. x x) (λx. x x)

cormullion

#20
I love clarity, simplicity, and economy too...



Given a choice between using 'awk' and deciphering regex - um, can I have another choice?  :-)

HPW

#21
There is a new companion-product of Regexbuddy:



http://www.regexmagic.com/">http://www.regexmagic.com/



This is not a regex editor, it seems to be a generator.

I will have a closer look.
Hans-Peter

newdep

#22
heeee cormullion..I completly missed your enhancement on this tool..



need to download that right away... A nice visual addon for my

"Perl 5 Desktop Reference pocket from 1996" ;-) I just recovered

from shelf, hidden behind a Tcl-Pedia-Book the size of a b/w-TV

(a good place to hide btw.. being a pocket containing Perl..)..
-- (define? (Cornflakes))

newdep

#23
.. Only 19.95 euro for a regEx tool..



Great.. now if they only would remove the regex-part from it,

which is clearly simply with that tool,i would be pleased to pay

'Only 19.95 euro'  for it..



Meanwhile im doing, and will be for the next week,

some masogistic regex debugging I not happy about..
-- (define? (Cornflakes))

cormullion

#24
you mean http://unbalanced-parentheses.nfshost.com/downloads/grepper.lsp.txt.src.html">//http://unbalanced-parentheses.nfshost.com/downloads/grepper.lsp.txt.src.html ? I suppose that still works?!