зеркало из https://github.com/github/ruby.git
Fix ruby-electric-curlies.
* misc/ruby-electric.el (ruby-electric-curlies): Fix the bug where an open curly is always replaced with a hash sign. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38895 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
7d6f22f4cd
Коммит
9545483ad3
|
@ -1,3 +1,8 @@
|
||||||
|
Tue Jan 22 22:58:03 2013 Akinori MUSHA <knu@iDaemons.org>
|
||||||
|
|
||||||
|
* misc/ruby-electric.el (ruby-electric-curlies): Fix the bug where
|
||||||
|
an open curly is always replaced with a hash sign.
|
||||||
|
|
||||||
Mon Jan 21 15:41:33 2013 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Mon Jan 21 15:41:33 2013 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* tool/mkconfig.rb: BASERUBY is transient at core build.
|
* tool/mkconfig.rb: BASERUBY is transient at core build.
|
||||||
|
|
|
@ -175,13 +175,10 @@ strings. Note that you must have Font Lock enabled."
|
||||||
(insert "}"))))
|
(insert "}"))))
|
||||||
((ruby-electric-string-at-point-p)
|
((ruby-electric-string-at-point-p)
|
||||||
(if (eq last-command-event ?{)
|
(if (eq last-command-event ?{)
|
||||||
(save-excursion
|
|
||||||
(when (not (char-equal ?\# (preceding-char)))
|
|
||||||
(kill-region (point) (1- (point)))
|
|
||||||
(insert "#"))))
|
|
||||||
(save-excursion
|
(save-excursion
|
||||||
(backward-char 1)
|
(backward-char 1)
|
||||||
(when (char-equal ?\# (preceding-char))
|
(or (char-equal ?\# (preceding-char))
|
||||||
|
(insert "#"))
|
||||||
(forward-char 1)
|
(forward-char 1)
|
||||||
(insert "}")))))))
|
(insert "}")))))))
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче