summaryrefslogtreecommitdiff
path: root/misc
diff options
context:
space:
mode:
Diffstat (limited to 'misc')
-rw-r--r--misc/inf-ruby.el7
-rw-r--r--misc/ruby-mode.el12
2 files changed, 8 insertions, 11 deletions
diff --git a/misc/inf-ruby.el b/misc/inf-ruby.el
index eaa904951c..f192147a37 100644
--- a/misc/inf-ruby.el
+++ b/misc/inf-ruby.el
@@ -18,7 +18,7 @@
;;; "Mode for editing ruby source files")
;;; (setq auto-mode-alist
;;; (append '(("\\.rb$" . ruby-mode)) auto-mode-alist))
-;;; (setq interpreter-mode-alist (append '(("^#!.*ruby" . ruby-mode))
+;;; (setq interpreter-mode-alist (append '(("ruby" . ruby-mode))
;;; interpreter-mode-alist))
;;;
;;; (2) set to road inf-ruby and set inf-ruby key definition in ruby-mode.
@@ -35,9 +35,12 @@
;;; HISTORY
;;; senda - 8 Apr 1998: Created.
;;; $Log$
+;;; Revision 1.2.2.1 1999/12/01 09:24:48 matz
+;;; 19991201
+;;;
;;; Revision 1.2 1999/08/13 05:45:18 matz
;;; 1.4.0
-;;;
+;;;
;;; Revision 1.1.1.1.2.1 1999/07/15 07:59:59 matz
;;; 990715
;;;
diff --git a/misc/ruby-mode.el b/misc/ruby-mode.el
index 50e4f50e87..5ebf4f875e 100644
--- a/misc/ruby-mode.el
+++ b/misc/ruby-mode.el
@@ -180,12 +180,7 @@ The variable ruby-indent-level controls the amount of indentation.
(back-to-indentation)
(setq top (current-column))
(skip-chars-backward " \t")
- (cond
- ((>= x shift)
- (setq shift 0))
- ((>= shift top)
- (setq shift (- shift top)))
- (t (setq shift 0)))
+ (if (>= shift top) (setq shift (- shift top)))
(if (and (bolp)
(= x top))
(move-to-column (+ x shift))
@@ -669,7 +664,6 @@ An end of a defun is found by moving forward from the beginning of one."
"return"
"then"
"throw"
- "self"
"super"
"unless"
"undef"
@@ -681,8 +675,8 @@ An end of a defun is found by moving forward from the beginning of one."
"\\)\\>[^_]")
2)
;; variables
- '("\\b\\(nil\\|self\\|true\\|false\\)\\b"
- 1 font-lock-variable-name-face)
+ '("\\(^\\|[^_:.@$]\\|\\.\\.\\)\\b\\(nil\\|self\\|true\\|false\\)\\b[^_]"
+ 2 font-lock-variable-name-face)
;; variables
'("[$@].\\(\\w\\|_\\)*"
0 font-lock-variable-name-face)