From: | Martijn van Oosterhout <kleptog(at)svana(dot)org> |
---|---|
To: | Magnus Hagander <magnus(at)hagander(dot)net> |
Cc: | Andrew Dunstan <andrew(at)dunslane(dot)net>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: MSVC build broken with perl 5.10 |
Date: | 2008-04-10 14:53:28 |
Message-ID: | 20080410145327.GB5536@svana.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-patches |
On Thu, Apr 10, 2008 at 04:12:56PM +0200, Magnus Hagander wrote:
> > > my $replace_re =
> > > qr{^([^:\n\$]+\.c)\s*:\s*(?:%\s*: )?\$(\([^\)]+\))\/(.*)\/[^\/]+$};
> > Perhaps you would like to comment it using the x format, so that it
> > doesn't just look like white noise.
>
> That would be a good idea, no? ;-) I have no idea what you mean with
> "using the x format", though, but I agree in general that the
> white-noise format is not a good idea...
Using x format modifier means you can put comments and whitespace in your regex, like:
my $replace_re = qr{^([^:\n\$]+\.c) # This matches the filename in $1
\s*:\s*(?:%\s*:\ )? # somethig with a %-sign
...etc...
}x;
Check the perlre manpage for more info.
Have a nice day,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> Please line up in a tree and maintain the heap invariant while
> boarding. Thank you for flying nlogn airlines.
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2008-04-10 14:56:04 | Re: Commit fest queue |
Previous Message | Joshua D. Drake | 2008-04-10 14:51:09 | Re: [HACKERS] [SQL] pl/PgSQL, variable names in NEW |
From | Date | Subject | |
---|---|---|---|
Next Message | Gregory Stark | 2008-04-10 14:56:49 | Re: [PATCHES] libpq type system 0.9a |
Previous Message | Gregory Stark | 2008-04-10 14:46:10 | Re: Concurrent psql API |