in reply to
Re: Changing the first word to uppercase
in thread
Changing the first word to uppercase
What's the reason you chose
s/.../uc($1)/e
over
s/.../\U$1/
?
Comment on
Re^2: Changing the first word to uppercase
Select
or
Download
Code
Replies are listed 'Best First'.
Re^3: Changing the first word to uppercase
by
ikegami
(Patriarch)
on Feb 14, 2008 at 18:24 UTC
I only thought of
\U
afterwards. I'm not a big fan of it either. Code shouldn't look like a string literal. And unlike interpolation, it's not something we are trained to look for.
[reply]
[d/l]
In Section
Seekers of Perl Wisdom