[re: <<-|FOO, <<|FOO, <<|]
While I like the proposed functionality, I agree with matz that it’s not really “intuitive.” Why not take the most radical and combine it with a variant of the Perl6 syntax?
foo = <<<|
Sent from my Treo
From: Dave Thomas
Date: 03.1.15 11.01
To: firstname.lastname@example.org (ruby-talk ML)
Subj: Re: ruby-dev summary 19198-19345
Matt Armstrong wrote:
I just though, why not “<<|FOO”. In other words, the ‘-’ in there
doesn’t serve much purpose.
s = <<|FOO
In fact, neither does the ‘FOO’
s = <<|Now is the time > For all good men > to code Ruby p s.length
So any line that doesn’t start with the given delimiter (ignoring
leading whitespace) ends the string.