1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-11 14:01:43 -08:00

Backport: ruby-mode: Expect regexp after { or | too

Fixes: debbugs:20026

* progmodes/ruby-mode.el (ruby-syntax-before-regexp-re): Expect
beginning of regexp also after open brace or vertical bar.

(cherry picked from commit dad0fc589c)
This commit is contained in:
Nobuyoshi Nakada 2015-03-20 06:04:36 +02:00 committed by Dmitry Gutov
parent 1a941d6c9e
commit a5d1f94fec
2 changed files with 7 additions and 1 deletions

View file

@ -1,3 +1,9 @@
2015-03-20 Nobuyoshi Nakada <nobu@ruby-lang.org>
* progmodes/ruby-mode.el (ruby-syntax-before-regexp-re): Expect
beginning of regexp also after open brace or vertical bar.
(Bug#20026)
2015-03-07 Michael Albinus <michael.albinus@gmx.de>
* net/tramp.el (tramp-ssh-controlmaster-options): Make it a

View file

@ -1777,7 +1777,7 @@ It will be properly highlighted even when the call omits parens.")
(defvar ruby-syntax-before-regexp-re
(concat
;; Special tokens that can't be followed by a division operator.
"\\(^\\|[[=(,~;<>]"
"\\(^\\|[[{|=(,~;<>]"
;; Distinguish ternary operator tokens.
;; FIXME: They don't really have to be separated with spaces.
"\\|[?:] "