summaryrefslogtreecommitdiff
path: root/sample/ruby-mode.el
diff options
context:
space:
mode:
authorYukihiro Matsumoto <matz@ruby-lang.org>1994-10-14 06:19:03 +0900
committerTakashi Kokubun <takashikkbn@gmail.com>2019-08-17 22:09:30 +0900
commit29f237a8b1df650089b54447f070726c75706b6f (patch)
treee6ee836a39a5f2f1d433d6532de32471b655fb6d /sample/ruby-mode.el
parent173976c97c9426aa8d96e53aef6c0e570c5fdfda (diff)
version 0.54v0_54
https://cache.ruby-lang.org/pub/ruby/1.0/ruby-0.54.tar.gz
Diffstat (limited to 'sample/ruby-mode.el')
-rw-r--r--sample/ruby-mode.el5
1 files changed, 4 insertions, 1 deletions
diff --git a/sample/ruby-mode.el b/sample/ruby-mode.el
index 8f864d3..7f97e71 100644
--- a/sample/ruby-mode.el
+++ b/sample/ruby-mode.el
@@ -18,7 +18,7 @@
(defconst ruby-block-end-re "end")
(defconst ruby-delimiter
- (concat "[/<(){}#\"'`]\\|\\[\\|\\]\\|\\b\\("
+ (concat "[$/<(){}#\"'`]\\|\\[\\|\\]\\|\\b\\("
ruby-block-beg-re "\\|" ruby-block-end-re "\\)\\b")
)
@@ -55,6 +55,7 @@
;;(modify-syntax-entry ?\n ">" ruby-mode-syntax-table)
;;(modify-syntax-entry ?\f ">" ruby-mode-syntax-table)
(modify-syntax-entry ?# "<" ruby-mode-syntax-table)
+ (modify-syntax-entry ?$ "/" ruby-mode-syntax-table)
(modify-syntax-entry ?\\ "'" ruby-mode-syntax-table)
(modify-syntax-entry ?_ "w" ruby-mode-syntax-table)
(modify-syntax-entry ?< "." ruby-mode-syntax-table)
@@ -193,6 +194,8 @@ The variable ruby-indent-level controls the amount of indentation.
nil
(goto-char indent-point)
(setq in-string t))))))
+ ((string= "$" w) ;skip $char
+ (forward-char 1))
((string= "#" w) ;skip comment
(forward-line 1))
((string= "(" w) ;skip to matching paren