emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] * lisp/progmodes/ruby-mode.el: Mark defcustoms as safe with


From: Dmitry Gutov
Subject: Re: [PATCH] * lisp/progmodes/ruby-mode.el: Mark defcustoms as safe with :safe keyword argument.
Date: Fri, 01 Nov 2013 07:36:19 +0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

Installed with small modification, thanks.

Bozhidar Batsov <address@hidden> writes:
> Just a minor improvement to ruby-mode’s defcustoms. 
>
> -- 
> Cheers,
> Bozhidar
>
>
>
> From 37d763ea2a241bfbe8a53a62b8f19d5f1edf0f13 Mon Sep 17 00:00:00 2001
> From: Bozhidar Batsov <address@hidden>
> Date: Thu, 31 Oct 2013 15:16:58 +0200
> Subject: [PATCH] * lisp/progmodes/ruby-mode.el: Mark defcustoms as safe with
>  :safe   keyword argument.
>
> ---
>  lisp/progmodes/ruby-mode.el | 14 ++++----------
>  1 file changed, 4 insertions(+), 10 deletions(-)
>
> diff --git a/lisp/progmodes/ruby-mode.el b/lisp/progmodes/ruby-mode.el
> index 441f166..d92928b 100644
> --- a/lisp/progmodes/ruby-mode.el
> +++ b/lisp/progmodes/ruby-mode.el
> @@ -216,20 +216,20 @@ This should only be called after matching against 
> `ruby-here-doc-beg-re'."
>  
>  (defcustom ruby-indent-tabs-mode nil
>    "Indentation can insert tabs in Ruby mode if this is non-nil."
> -  :type 'boolean :group 'ruby)
> +  :type 'boolean :group 'ruby :safe 'booleanp)
>  
>  (defcustom ruby-indent-level 2
>    "Indentation of Ruby statements."
> -  :type 'integer :group 'ruby)
> +  :type 'integer :group 'ruby :safe 'integerp)
>  
>  (defcustom ruby-comment-column (default-value 'comment-column)
>    "Indentation column of comments."
> -  :type 'integer :group 'ruby)
> +  :type 'integer :group 'ruby :safe 'integerp)
>  
>  (defcustom ruby-deep-arglist t
>    "Deep indent lists in parenthesis when non-nil.
>  Also ignores spaces after parenthesis when 'space."
> -  :group 'ruby)
> +  :type 'boolean :group 'ruby :safe 'booleanp)
>  
>  (defcustom ruby-deep-indent-paren '(?\( ?\[ ?\] t)
>    "Deep indent lists in parenthesis when non-nil.
> @@ -260,12 +260,6 @@ explicitly declared in magic comment."
>    "Use `ruby-encoding-map' to set encoding magic comment if this is non-nil."
>    :type 'boolean :group 'ruby)
>  
> -;; Safe file variables
> -(put 'ruby-indent-tabs-mode 'safe-local-variable 'booleanp)
> -(put 'ruby-indent-level 'safe-local-variable 'integerp)
> -(put 'ruby-comment-column 'safe-local-variable 'integerp)
> -(put 'ruby-deep-arglist 'safe-local-variable 'booleanp)
> -
>  ;;; SMIE support
>  
>  (require 'smie)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]