Stop recognizing :#{} as symbol in ruby-mode
* lisp/progmodes/ruby-mode.el (ruby-font-lock-keywords): Remove the weird part that recognized colon followed by interpolation construct without quotes (e.g. ':#{abc}') as symbol, which is just a syntax error in any modern version of Ruby. Fix nearby bug reference.
This commit is contained in:
parent
366ec7719f
commit
9b16bc2a01
1 changed files with 2 additions and 2 deletions
|
@ -2188,11 +2188,11 @@ See `font-lock-syntax-table'.")
|
||||||
(2 font-lock-constant-face)
|
(2 font-lock-constant-face)
|
||||||
(3 (unless (and (eq (char-before (match-end 3)) ?=)
|
(3 (unless (and (eq (char-before (match-end 3)) ?=)
|
||||||
(eq (char-after (match-end 3)) ?>))
|
(eq (char-after (match-end 3)) ?>))
|
||||||
;; bug#18466
|
;; bug#18644
|
||||||
font-lock-constant-face)
|
font-lock-constant-face)
|
||||||
nil t))
|
nil t))
|
||||||
;; Symbols with special characters.
|
;; Symbols with special characters.
|
||||||
("\\(^\\|[^:]\\)\\(:\\([-+~]@?\\|[/%&|^`]\\|\\*\\*?\\|<\\(<\\|=>?\\)?\\|>[>=]?\\|===?\\|=~\\|![~=]?\\|\\[\\]=?\\|#{[^}\n\\\\]*\\(\\\\.[^}\n\\\\]*\\)*}\\)\\)"
|
("\\(^\\|[^:]\\)\\(:\\([-+~]@?\\|[/%&|^`]\\|\\*\\*?\\|<\\(<\\|=>?\\)?\\|>[>=]?\\|===?\\|=~\\|![~=]?\\|\\[\\]=?\\)\\)"
|
||||||
2 font-lock-constant-face)
|
2 font-lock-constant-face)
|
||||||
;; Special globals.
|
;; Special globals.
|
||||||
(,(concat "\\$\\(?:[:\"!@;,/\\._><\\$?~=*&`'+0-9]\\|-[0adFiIlpvw]\\|"
|
(,(concat "\\$\\(?:[:\"!@;,/\\._><\\$?~=*&`'+0-9]\\|-[0adFiIlpvw]\\|"
|
||||||
|
|
Loading…
Add table
Reference in a new issue