From: sawadatsuyoshi@... Date: 2015-12-25T16:20:10+00:00 Subject: [ruby-core:72479] [Ruby trunk - Bug #11871] [Open] Heredoc unindentation with <<~ with single-quoted identifier flush-lefts the content Issue #11871 has been reported by Tsuyoshi Sawada. ---------------------------------------- Bug #11871: Heredoc unindentation with <<~ with single-quoted identifier flush-lefts the content https://bugs.ruby-lang.org/issues/11871 * Author: Tsuyoshi Sawada * Status: Open * Priority: Normal * Assignee: * ruby -v: 2.3.0p0 (2015-12-25 revision 53290) [x86_64-linux] * Backport: 2.0.0: UNKNOWN, 2.1: UNKNOWN, 2.2: UNKNOWN, 2.3: UNKNOWN ---------------------------------------- Heredoc unindentation with `<<~` works as expected when the identifier is bare or double-quoted: ~~~ s = <<~_ fiwfewifjf iofwejfweifwe fjiofwejfweiof f fiwejfweof _ puts s ~~~ or ~~~ s = <<~"_" fiwfewifjf iofwejfweifwe fjiofwejfweiof f fiwejfweof _ puts s ~~~ Output: ~~~ fiwfewifjf iofwejfweifwe fjiofwejfweiof f fiwejfweof ~~~ But with a single-quoted identifier, the content is flushed left: ~~~ s = <<~'_' fiwfewifjf iofwejfweifwe fjiofwejfweiof f fiwejfweof _ puts s ~~~ Output: ~~~ fiwfewifjf iofwejfweifwe fjiofwejfweiof f fiwejfweof ~~~ -- https://bugs.ruby-lang.org/ Unsubscribe: