On Mon, Oct 5, 2009 at 6:12 PM, Trent W. Buck <[email protected]>wrote:
> Nathan Gray <[email protected]> writes: > > > On Sat, Oct 03, 2009 at 01:32:38AM -0700, Jason Dagit wrote: > >> Specifically, our current list looks like: > >> \.(foo|FOO)$ > >> > >> I think we should transform that to: > >> \.[fF][oO][oO]$ > >> > >> I think that better captures the case-insensitive intent that we had. > > > > If we want case-insensitive, can't we use a case-insensitive flag? > > > > (?i)\.foo$ > > > > That's how it's written for Perl. I'm not sure of the syntax outside > > of Perl. > > AIUI we currently use EREs, so are restricted to the functionality > mentioned in regex(7). That has no equivalent for (?i) other than > [fF][oO]... > Since we read in the file and then process it a bit before handing it the regular expression implementation we could actually implement what Nathan describes. Someone would need to profile it to see if it's worth it or somehow argue that users lives are going to be much much easier. Alternatively, it's something that our hypothetical regex optimizer could detect and handle in whatever way is considered efficient by it. Having said that, I would actually argue against adding support for case-insensitive matches in this way because it's the sort of change that requires us to bump the repository format causing incompatibilities between darcsen. So the benefits would need to be clear. Otherwise what do we tell the people that are inconvenienced by the change? Jason
_______________________________________________ darcs-users mailing list [email protected] http://lists.osuosl.org/mailman/listinfo/darcs-users
