Mark J. Reed wrote: > On Sat, Jul 25, 2009 at 5:03 AM, Moritz Lenz<mor...@faui2k3.org> wrote: >> Presumably you want here-docs, which can be indented in Perl 6: >> >> perl 6 code >> perl 6 code >> $script.say(Q:to<END>); >> output code >> output code >> END >> >> The leading whitespace will be pruned from the string. > > All of the leading whitespace, or only up to the amount on the first > line?
only the amount before the END marker actually. Sorry for not being precise in the first place. See S02:3399 for more details. > That's always been the problem with here-docs. Rakudo doesn't > seem to support Q:to yet, so I can't test, but if I do this: > > say(Q:to<END>); > line 1 > line 2 > line 3 > END > > I would want line1 to be flush left, while line 2 is indented, and > line 3 indented more. Then it'll DWYM ;-) Cheers, Moritz