[Python-Dev] Re: Missing arguments in RE functions (original) (raw)
Nicolas Fleury nidoizo at yahoo.com
Fri Sep 10 05:37:39 CEST 2004
- Previous message: [Python-Dev] Re: Missing arguments in RE functions
- Next message: [Python-Dev] Re: Missing arguments in RE functions
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Fredrik Lundh wrote:
Noam Raphael wrote:
This is why I didn't even know, until I made my research before sending my message to python-dev, that you could match from a given start position - I studied the page documenting the functions, because I didn't want on an early stage to bother my students with the fact that REs are first compiled and then applied, and I didn't find any mention of the start position option. the "I didn't prepare properly, didn't know what I was talking about, and didn't know what do answer when my students asked me a legitimate question" argument isn't a good reason to change the language. if you're doing Python training, make sure you know your Python. I do, and I very seldom have problems explaining how things work.
I don't know what in Noam requests justify what I read as insults (and hope were not intended to be). I think Noam's point is just that the function API can be considered incomplete/incoherent when compared to the one with pattern objects. It's debatable and personally I always use pattern objects. It basically depends on the goals of the redundant function API, and I have no idea what they are.
I tend to agree with Raymond. FWIW, I think it's clearer to define the function API as pattern objects equivalent in functionality than as shortcuts for trivial cases. However, as you pointed, the advantage of not extending the API forces moving the pattern objects. (I also give Python courses, but to be honest I teach regular expressions in Perl, avoiding focusing on compilation issues.)
Regards, Nicolas
- Previous message: [Python-Dev] Re: Missing arguments in RE functions
- Next message: [Python-Dev] Re: Missing arguments in RE functions
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]