diff options
| author | Bozhidar Batsov | 2013-11-01 07:35:35 +0400 |
|---|---|---|
| committer | Dmitry Gutov | 2013-11-01 07:35:35 +0400 |
| commit | 983d0df5e186d445d2b1936536363e9343fd0c60 (patch) | |
| tree | 0e8cd3b4b5c6cad31118128f65f4a741ab26ec57 /lisp/progmodes/ruby-mode.el | |
| parent | cb16270e14907075bfc8cdbb014a550b550c70b7 (diff) | |
| download | emacs-983d0df5e186d445d2b1936536363e9343fd0c60.tar.gz emacs-983d0df5e186d445d2b1936536363e9343fd0c60.zip | |
* lisp/progmodes/ruby-mode.el (ruby-indent-tabs-mode)
(ruby-indent-level, ruby-comment-column, ruby-deep-arglist):
Add property :safe.
(ruby-deep-arglist): Add property :type.
Diffstat (limited to 'lisp/progmodes/ruby-mode.el')
| -rw-r--r-- | lisp/progmodes/ruby-mode.el | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/lisp/progmodes/ruby-mode.el b/lisp/progmodes/ruby-mode.el index 441f166396e..1a49f705dcb 100644 --- a/lisp/progmodes/ruby-mode.el +++ b/lisp/progmodes/ruby-mode.el | |||
| @@ -216,20 +216,28 @@ This should only be called after matching against `ruby-here-doc-beg-re'." | |||
| 216 | 216 | ||
| 217 | (defcustom ruby-indent-tabs-mode nil | 217 | (defcustom ruby-indent-tabs-mode nil |
| 218 | "Indentation can insert tabs in Ruby mode if this is non-nil." | 218 | "Indentation can insert tabs in Ruby mode if this is non-nil." |
| 219 | :type 'boolean :group 'ruby) | 219 | :type 'boolean |
| 220 | :group 'ruby | ||
| 221 | :safe 'booleanp) | ||
| 220 | 222 | ||
| 221 | (defcustom ruby-indent-level 2 | 223 | (defcustom ruby-indent-level 2 |
| 222 | "Indentation of Ruby statements." | 224 | "Indentation of Ruby statements." |
| 223 | :type 'integer :group 'ruby) | 225 | :type 'integer |
| 226 | :group 'ruby | ||
| 227 | :safe 'integerp) | ||
| 224 | 228 | ||
| 225 | (defcustom ruby-comment-column (default-value 'comment-column) | 229 | (defcustom ruby-comment-column (default-value 'comment-column) |
| 226 | "Indentation column of comments." | 230 | "Indentation column of comments." |
| 227 | :type 'integer :group 'ruby) | 231 | :type 'integer |
| 232 | :group 'ruby | ||
| 233 | :safe 'integerp) | ||
| 228 | 234 | ||
| 229 | (defcustom ruby-deep-arglist t | 235 | (defcustom ruby-deep-arglist t |
| 230 | "Deep indent lists in parenthesis when non-nil. | 236 | "Deep indent lists in parenthesis when non-nil. |
| 231 | Also ignores spaces after parenthesis when 'space." | 237 | Also ignores spaces after parenthesis when 'space." |
| 232 | :group 'ruby) | 238 | :type 'boolean |
| 239 | :group 'ruby | ||
| 240 | :safe 'booleanp) | ||
| 233 | 241 | ||
| 234 | (defcustom ruby-deep-indent-paren '(?\( ?\[ ?\] t) | 242 | (defcustom ruby-deep-indent-paren '(?\( ?\[ ?\] t) |
| 235 | "Deep indent lists in parenthesis when non-nil. | 243 | "Deep indent lists in parenthesis when non-nil. |
| @@ -260,12 +268,6 @@ explicitly declared in magic comment." | |||
| 260 | "Use `ruby-encoding-map' to set encoding magic comment if this is non-nil." | 268 | "Use `ruby-encoding-map' to set encoding magic comment if this is non-nil." |
| 261 | :type 'boolean :group 'ruby) | 269 | :type 'boolean :group 'ruby) |
| 262 | 270 | ||
| 263 | ;; Safe file variables | ||
| 264 | (put 'ruby-indent-tabs-mode 'safe-local-variable 'booleanp) | ||
| 265 | (put 'ruby-indent-level 'safe-local-variable 'integerp) | ||
| 266 | (put 'ruby-comment-column 'safe-local-variable 'integerp) | ||
| 267 | (put 'ruby-deep-arglist 'safe-local-variable 'booleanp) | ||
| 268 | |||
| 269 | ;;; SMIE support | 271 | ;;; SMIE support |
| 270 | 272 | ||
| 271 | (require 'smie) | 273 | (require 'smie) |