diff options
| -rw-r--r-- | lisp/progmodes/ruby-mode.el | 2 | ||||
| -rw-r--r-- | test/indent/ruby.rb | 4 |
2 files changed, 5 insertions, 1 deletions
diff --git a/lisp/progmodes/ruby-mode.el b/lisp/progmodes/ruby-mode.el index 53f8a6bb4c0..e3fe315f3bd 100644 --- a/lisp/progmodes/ruby-mode.el +++ b/lisp/progmodes/ruby-mode.el | |||
| @@ -102,7 +102,7 @@ | |||
| 102 | 102 | ||
| 103 | (eval-and-compile | 103 | (eval-and-compile |
| 104 | (defconst ruby-here-doc-beg-re | 104 | (defconst ruby-here-doc-beg-re |
| 105 | "\\(<\\)<\\(-\\)?\\(\\([a-zA-Z0-9_]+\\)\\|[\"]\\([^\"]+\\)[\"]\\|[']\\([^']+\\)[']\\)" | 105 | "\\(<\\)<\\([~-]\\)?\\(\\([a-zA-Z0-9_]+\\)\\|[\"]\\([^\"]+\\)[\"]\\|[']\\([^']+\\)[']\\)" |
| 106 | "Regexp to match the beginning of a heredoc.") | 106 | "Regexp to match the beginning of a heredoc.") |
| 107 | 107 | ||
| 108 | (defconst ruby-expression-expansion-re | 108 | (defconst ruby-expression-expansion-re |
diff --git a/test/indent/ruby.rb b/test/indent/ruby.rb index dec6de98605..dfd1c75a679 100644 --- a/test/indent/ruby.rb +++ b/test/indent/ruby.rb | |||
| @@ -4,6 +4,10 @@ if something_wrong? # ruby-move-to-block-skips-heredoc | |||
| 4 | end | 4 | end |
| 5 | eowarn | 5 | eowarn |
| 6 | foo | 6 | foo |
| 7 | |||
| 8 | foo(<<~squiggly) | ||
| 9 | end | ||
| 10 | squiggly | ||
| 7 | end | 11 | end |
| 8 | 12 | ||
| 9 | def foo | 13 | def foo |