summaryrefslogtreecommitdiff
path: root/doc/syntax
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2023-03-15 14:35:32 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2023-03-19 18:10:55 +0900
commite7342e76dfd26237c604e42f9a59a1eaa578c94e (patch)
tree63e55f4648f9869869b9e4be8df75edf097f072f /doc/syntax
parent9654a28cc5bbf55e200806a0c62c6e17b1635e1c (diff)
[Bug #19485] [DOC] Mention tabs in indentation of heredoc identifier
Co-Authored-By: sawa (Tsuyoshi Sawada) <sawadatsuyoshi@gmail.com>
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/7526
Diffstat (limited to 'doc/syntax')
-rw-r--r--doc/syntax/literals.rdoc6
1 files changed, 6 insertions, 0 deletions
diff --git a/doc/syntax/literals.rdoc b/doc/syntax/literals.rdoc
index 5e10e6a140..b641433249 100644
--- a/doc/syntax/literals.rdoc
+++ b/doc/syntax/literals.rdoc
@@ -277,6 +277,12 @@ the content. Note that empty lines and lines consisting solely of literal tabs
and spaces will be ignored for the purposes of determining indentation, but
escaped tabs and spaces are considered non-indentation characters.
+For the purpose of measuring an indentation, a horizontal tab is regarded as a
+sequence of one to eight spaces such that the column position corresponding to
+its end is a multiple of eight. The amount to be removed is counted in terms
+of the number of spaces. If the boundary appears in the middle of a tab, that
+tab is not removed.
+
A heredoc allows interpolation and escaped characters. You may disable
interpolation and escaping by surrounding the opening identifier with single
quotes: