Re: [PATCH] Add .trim method
[email protected] (jesse) Mon, 12 Jan 2009 10:07:21 -0500
| Newsgroups | perl.perl6.language,perl.perl6.internals |
|---|---|
| Message-ID | <[email protected]> |
On Mon, Jan 12, 2009 at 07:01:25AM -0800, Ovid wrote: > > > > I could optionally make the following work: > > > > > > > > $string.trim(:leading<0>); > > > > $string.trim(:trailing<0>); > > Alternatively, those could be ltrim() and rtrim(). 'left' and 'right' are probably not the right names for functions which trim leading and/or trailing space, since their meanings get somewhat ambiguous if a language renders right-to-left instead of left-to-right or vice-versa -jesse