Regular language [entries|reading|network|archive]
simont

[ userinfo | dreamwidth userinfo ]
[ archive | journal archive ]

Tue 2016-06-21 08:47
Regular language
LinkReply
[personal profile] simontTue 2016-06-21 07:51
I always used to be a 'regexp' person, but prolonged exposure to 'regex' seems to have recently built up enough activation energy to switch me over.

Now I'm on the other side, I find myself wondering what the point of the p was in the first place – 'regex' is adequately unambiguous and takes fewer characters, so what's not to like? But I can't remember why I adopted the p spelling myself. I'd be quite interested to know whether there are any centralised sources (particular textbooks, library APIs, influential articles or some such) that might be responsible for popularising one or the other.
Link Reply to this | Thread
[personal profile] stephdairyTue 2016-06-21 08:06
The perl manpages use regexp.
Link Reply to this | Parent
[personal profile] atreicTue 2016-06-21 08:27
It's nicer when both bits of the abbreviation are the same length?
Link Reply to this | Parent | Thread
[personal profile] simontTue 2016-06-21 08:31
I hadn't thought of that, though the thought has just occurred to me that 'exp' by itself, shorn of the 'reg' prefix, makes a more comprehensible abbreviation of 'expression' than 'ex' does.
Link Reply to this | Parent
[personal profile] jackTue 2016-06-21 09:45
I was thinking that. I think I use regexp occasionally but regex more. I *think* I learned regexp first, but it eroded quickly, but I'm not sure, it could have been the other way round.
Link Reply to this | Parent
[personal profile] ptc24Tue 2016-06-21 10:57
I know that python, Java and C# prefer "regex", JavaScript prefers "regexp", R is inconsistent.
Link Reply to this | Parent | Thread
[personal profile] damerellTue 2016-06-21 17:39
Perl (at least "man perlre") prefers "regexp".
Link Reply to this | Parent
navigation
[ go | Previous Entry | Next Entry ]
[ add | to Memories ]