From: Trans Date: 2011-10-04T23:39:19+09:00 Subject: [ruby-core:39930] Re: Discussion results (here documents with indents) On Tue, Oct 4, 2011 at 2:47 AM, Jim Freeze wrote: > I'm not convinced yet this belongs in Ruby. > The only argument I have heard for this is because 'left shifting' a block > of text 'looks bad'. You say that like it's not important. I fundamentally disagree with your dismissive tone. That's the only argument there needs to be. I would argue that *readability* is the most significant feature that sets Ruby apart. Ruby can keep all it's other excellent features, but if it's syntax were like Javascript I would have never bothered a second glance at it. Don't underestimate 'looks'. > However, the solution looks even worse. Why such hyperbole? Clearly that is not true. You really think something like: module MyApp module Commands class Show def error_message(err) <<-HERE Error: #{err.class} #{err.message} HERE end end end end Is better than: module MyApp module Commands class Show def error_message(err) %L|Error: #{err.class} |#{err.message} end end end end > If a programmer doesn't like the left shift, put the text in a file of it's > own or put it in DATA. More overhead, even less readability. And what of interpolation?