* [PATCH] Fix all unescaped character literals
@ 2017-05-06 17:17 Philipp Stephani
2017-05-07 11:37 ` Philipp
0 siblings, 1 reply; 2+ messages in thread
From: Philipp Stephani @ 2017-05-06 17:17 UTC (permalink / raw)
To: emacs-devel; +Cc: Philipp Stephani
---
lisp/calendar/timeclock.el | 4 ++--
lisp/emulation/viper-cmd.el | 2 +-
lisp/language/japan-util.el | 2 +-
lisp/leim/quail/cyrillic.el | 8 ++++----
lisp/mh-e/mh-search.el | 4 ++--
lisp/nxml/xsd-regexp.el | 2 +-
lisp/obsolete/complete.el | 2 +-
lisp/obsolete/vi.el | 4 ++--
lisp/org/ob-ref.el | 2 +-
lisp/progmodes/ada-mode.el | 2 +-
lisp/progmodes/cperl-mode.el | 4 ++--
lisp/progmodes/gud.el | 8 ++++----
lisp/progmodes/idlw-shell.el | 4 ++--
lisp/progmodes/sh-script.el | 4 ++--
lisp/progmodes/tcl.el | 2 +-
lisp/progmodes/verilog-mode.el | 8 ++++----
lisp/skeleton.el | 4 ++--
lisp/woman.el | 2 +-
18 files changed, 34 insertions(+), 34 deletions(-)
diff --git a/lisp/calendar/timeclock.el b/lisp/calendar/timeclock.el
index f8de084f77..a4709c3b4b 100644
--- a/lisp/calendar/timeclock.el
+++ b/lisp/calendar/timeclock.el
@@ -656,9 +656,9 @@ timeclock-update-mode-line
(setq timeclock-mode-string
(propertize
(format " %c%s%c "
- (if last-in ?< ?[)
+ (if last-in ?< ?\[)
(timeclock-seconds-to-string remainder nil t)
- (if last-in ?> ?]))
+ (if last-in ?> ?\]))
'help-echo "timeclock: time remaining"))))
(put 'timeclock-mode-string 'risky-local-variable t)
diff --git a/lisp/emulation/viper-cmd.el b/lisp/emulation/viper-cmd.el
index 831b9c1ac2..a697aa7d03 100644
--- a/lisp/emulation/viper-cmd.el
+++ b/lisp/emulation/viper-cmd.el
@@ -90,7 +90,7 @@ viper-charpair-commands
(defconst viper-movement-commands '(?b ?B ?e ?E ?f ?F ?G ?h ?j ?k ?l
?H ?M ?L ?n ?t ?T ?w ?W ?$ ?%
- ?^ ?( ?) ?- ?+ ?| ?{ ?} ?[ ?] ?' ?`
+ ?^ ?\( ?\) ?- ?+ ?| ?{ ?} ?\[ ?\] ?' ?`
?\; ?, ?0 ?? ?/ ?\ ?\C-m
space return
delete backspace
diff --git a/lisp/language/japan-util.el b/lisp/language/japan-util.el
index abc8d7d6bc..01cdd8bef9 100644
--- a/lisp/language/japan-util.el
+++ b/lisp/language/japan-util.el
@@ -102,7 +102,7 @@ japanese-symbol-table
(?^[$B!'^[(B ?:) (?^[$B!(^[(B ?\;) (?^[$B!)^[(B ??) (?^[$B!*^[(B ?!) (?^[$B!+^[(B nil ?^[(I^^[(B) (?^[$B!,^[(B nil ?^[(I_^[(B)
(?^[$B!-^[(B ?') (?^[$B!.^[(B ?`) (?^[$B!0^[(B ?^) (?^[$B!2^[(B ?_) (?^[$B!<^[(B ?- ?^[(I0^[(B) (?^[$B!=^[(B ?-) (?^[$B!>^[(B ?-)
(?^[$B!?^[(B ?/) (?^[$B!@^[(B ?\\) (?^[$B!A^[(B ?~) (?^[$B!C^[(B ?|) (?^[$B!F^[(B ?`) (?^[$B!G^[(B ?') (?^[$B!H^[(B ?\") (?^[$B!I^[(B ?\")
- (?\^[$B!J^[(B ?\() (?\^[$B!K^[(B ?\)) (?\^[$B!N^[(B ?[) (?\^[$B!O^[(B ?]) (?\^[$B!P^[(B ?{) (?\^[$B!Q^[(B ?})
+ (?\^[$B!J^[(B ?\() (?\^[$B!K^[(B ?\)) (?\^[$B!N^[(B ?\[) (?\^[$B!O^[(B ?\]) (?\^[$B!P^[(B ?{) (?\^[$B!Q^[(B ?})
(?^[$B!R^[(B ?<) (?^[$B!S^[(B ?>) (?\^[$B!V^[(B nil ?\^[(I"^[(B) (?\^[$B!W^[(B nil ?\^[(I#^[(B)
(?^[$B!\^[(B ?+) (?^[$B!]^[(B ?-) (?^[$B!a^[(B ?=) (?^[$B!c^[(B ?<) (?^[$B!d^[(B ?>)
(?^[$B!l^[(B ?') (?^[$B!m^[(B ?\") (?^[$B!o^[(B ?\\) (?^[$B!p^[(B ?$) (?^[$B!s^[(B ?%) (?^[$B!t^[(B ?#) (?^[$B!u^[(B ?&) (?^[$B!v^[(B ?*)
diff --git a/lisp/leim/quail/cyrillic.el b/lisp/leim/quail/cyrillic.el
index af9f66c47f..600193ddc1 100644
--- a/lisp/leim/quail/cyrillic.el
+++ b/lisp/leim/quail/cyrillic.el
@@ -235,8 +235,8 @@
("^" ?:)
("&" ??)
("*" ?*)
- ("(" ?()
- (")" ?))
+ ("(" ?\()
+ (")" ?\))
("_" ?_)
("+" ?+)
("~" ?Ё)
@@ -789,8 +789,8 @@
("^" ?:)
("&" ??)
("*" ?*)
- ("(" ?()
- (")" ?))
+ ("(" ?\()
+ (")" ?\))
("_" ?_)
("+" ?+)
("~" ?')
diff --git a/lisp/mh-e/mh-search.el b/lisp/mh-e/mh-search.el
index 099f922a5e..0c2969f5ea 100644
--- a/lisp/mh-e/mh-search.el
+++ b/lisp/mh-e/mh-search.el
@@ -1517,8 +1517,8 @@ mh-index-generate-pretty-name
(setq string (mh-replace-string "-lbrace" " "))
(setq string (mh-replace-string "-rbrace" " "))
(setq string (mh-replace-string "-search" " "))
- (subst-char-in-region (point-min) (point-max) ?( ? t)
- (subst-char-in-region (point-min) (point-max) ?) ? t)
+ (subst-char-in-region (point-min) (point-max) ?\( ? t)
+ (subst-char-in-region (point-min) (point-max) ?\) ? t)
(subst-char-in-region (point-min) (point-max) ?- ? t)
(goto-char (point-min))
(while (and (not (eobp)) (memq (char-after) '(? ?\t ?\n ?\r ?_)))
diff --git a/lisp/nxml/xsd-regexp.el b/lisp/nxml/xsd-regexp.el
index 6acb1ff9d4..d56960c9fa 100644
--- a/lisp/nxml/xsd-regexp.el
+++ b/lisp/nxml/xsd-regexp.el
@@ -621,7 +621,7 @@ xsdre-single-escape
(defun xsdre-parse-escape ()
(let ((ch (car xsdre-current-regexp)))
(xsdre-advance)
- (cond ((memq ch '(?\\ ?| ?. ?- ?^ ?* ?+ ?( ?) ?{ ?} ?[ ?])) ch)
+ (cond ((memq ch '(?\\ ?| ?. ?- ?^ ?* ?+ ?\( ?\) ?{ ?} ?\[ ?\])) ch)
((eq ch ?r) ?\r)
((eq ch ?n) ?\n)
((eq ch ?t) ?\t)
diff --git a/lisp/obsolete/complete.el b/lisp/obsolete/complete.el
index a6c21bce87..6a7fdc59c2 100644
--- a/lisp/obsolete/complete.el
+++ b/lisp/obsolete/complete.el
@@ -570,7 +570,7 @@ PC-do-completion
(substring regex (1+ p)))
p (+ p (length PC-ndelims-regex) (length PC-delim-regex)))
(let ((bump (if (memq (aref regex p)
- '(?$ ?^ ?\. ?* ?+ ?? ?[ ?] ?\\))
+ '(?$ ?^ ?\. ?* ?+ ?? ?\[ ?\] ?\\))
-1 0)))
(setq regex (concat (substring regex 0 (+ p bump))
PC-ndelims-regex
diff --git a/lisp/obsolete/vi.el b/lisp/obsolete/vi.el
index 5b611aa2d0..a7a98d0ca5 100644
--- a/lisp/obsolete/vi.el
+++ b/lisp/obsolete/vi.el
@@ -1444,10 +1444,10 @@ vi-quote-words
(vi-set-last-change-command 'vi-quote-words arg char)
(if (not (looking-at "\\<")) (forward-word -1))
(insert char)
- (cond ((char-equal char ?[) (setq char ?]))
+ (cond ((char-equal char ?\[) (setq char ?\]))
((char-equal char ?{) (setq char ?}))
((char-equal char ?<) (setq char ?>))
- ((char-equal char ?() (setq char ?)))
+ ((char-equal char ?\() (setq char ?\)))
((char-equal char ?`) (setq char ?')))
(vi-end-of-word arg)
(forward-char 1)
diff --git a/lisp/org/ob-ref.el b/lisp/org/ob-ref.el
index 58cc2d96a6..1d26403035 100644
--- a/lisp/org/ob-ref.el
+++ b/lisp/org/ob-ref.el
@@ -133,7 +133,7 @@ org-babel-ref-resolve
;; if ref is indexed grab the indices -- beware nested indices
(when (and (string-match "\\[\\([^\\[]+\\)\\]$" ref)
(let ((str (substring ref 0 (match-beginning 0))))
- (= (org-count ?( str) (org-count ?) str))))
+ (= (org-count ?\( str) (org-count ?\) str))))
(setq index (match-string 1 ref))
(setq ref (substring ref 0 (match-beginning 0))))
;; assign any arguments to pass to source block
diff --git a/lisp/progmodes/ada-mode.el b/lisp/progmodes/ada-mode.el
index 10cca6a4a0..ab3ff3aa20 100644
--- a/lisp/progmodes/ada-mode.el
+++ b/lisp/progmodes/ada-mode.el
@@ -1664,7 +1664,7 @@ ada-activate-keys-for-case
ada-mode-map
(char-to-string key)
'ada-adjust-case-interactive)))
- '( ?` ?_ ?# ?% ?& ?* ?( ?) ?- ?= ?+
+ '( ?` ?_ ?# ?% ?& ?* ?\( ?\) ?- ?= ?+
?| ?\; ?: ?' ?\" ?< ?, ?. ?> ?/ ?\n 32 ?\r )))
(defun ada-loose-case-word (&optional _arg)
diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el
index 23ea91fe95..c0f1aaf39d 100644
--- a/lisp/progmodes/cperl-mode.el
+++ b/lisp/progmodes/cperl-mode.el
@@ -2173,8 +2173,8 @@ cperl-electric-paren
(insert (make-string
(prefix-numeric-value arg)
(cdr (assoc last-command-event '((?{ .?})
- (?[ . ?])
- (?( . ?))
+ (?\[ . ?\])
+ (?\( . ?\))
(?< . ?>))))))
(forward-char (- (prefix-numeric-value arg))))
(self-insert-command (prefix-numeric-value arg)))))
diff --git a/lisp/progmodes/gud.el b/lisp/progmodes/gud.el
index 7ab1442c64..8cb912706f 100644
--- a/lisp/progmodes/gud.el
+++ b/lisp/progmodes/gud.el
@@ -3118,10 +3118,10 @@ gud-expr-compound
(setq span-start (char-after (- span-start 1)))
(setq span-end (char-after span-end))
(cond
- ((= span-start ?)) t)
- ((= span-start ?]) t)
- ((= span-end ?() t)
- ((= span-end ?[) t)
+ ((= span-start ?\)) t)
+ ((= span-start ?\]) t)
+ ((= span-end ?\() t)
+ ((= span-end ?\[) t)
(t nil)))
(t nil))))
diff --git a/lisp/progmodes/idlw-shell.el b/lisp/progmodes/idlw-shell.el
index 1282f08b07..e7497e8e4f 100644
--- a/lisp/progmodes/idlw-shell.el
+++ b/lisp/progmodes/idlw-shell.el
@@ -4172,8 +4172,8 @@ idlwave-shell-mouse-nop
([(control ?t)] ?t idlwave-shell-toggle-toolbar)
([(control up)] up idlwave-shell-stack-up)
([(control down)] down idlwave-shell-stack-down)
- ([( ?[)] ?[ idlwave-shell-goto-previous-bp t t)
- ([( ?])] ?] idlwave-shell-goto-next-bp t t)
+ ([( ?\[)] ?\[ idlwave-shell-goto-previous-bp t t)
+ ([( ?\])] ?\] idlwave-shell-goto-next-bp t t)
([(control ?f)] ?f idlwave-shell-window)))
(mod (and (listp idlwave-shell-debug-modifiers)
idlwave-shell-debug-modifiers))
diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el
index a0bbf55a8f..db965c5a58 100644
--- a/lisp/progmodes/sh-script.el
+++ b/lisp/progmodes/sh-script.el
@@ -599,8 +599,8 @@ sh-mode-map
map)
"Keymap used in Shell-Script mode.")
-(defvar sh-skeleton-pair-default-alist '((?( _ ?)) (?\))
- (?[ ?\s _ ?\s ?]) (?\])
+(defvar sh-skeleton-pair-default-alist '((?\( _ ?\)) (?\))
+ (?\[ ?\s _ ?\s ?\]) (?\])
(?{ _ ?}) (?\}))
"Value to use for `skeleton-pair-default-alist' in Shell-Script mode.")
diff --git a/lisp/progmodes/tcl.el b/lisp/progmodes/tcl.el
index 2c7ce03665..902a5aace0 100644
--- a/lisp/progmodes/tcl.el
+++ b/lisp/progmodes/tcl.el
@@ -1524,7 +1524,7 @@ tcl-popup-menu
(defun tcl-quote (string)
"Quote STRING according to Tcl rules."
(mapconcat (lambda (char)
- (if (memq char '(?[ ?] ?{ ?} ?\\ ?\" ?$ ?\s ?\;))
+ (if (memq char '(?\[ ?\] ?{ ?} ?\\ ?\" ?$ ?\s ?\;))
(concat "\\" (char-to-string char))
(char-to-string char)))
string ""))
diff --git a/lisp/progmodes/verilog-mode.el b/lisp/progmodes/verilog-mode.el
index 9f3bad1c1a..4860ea2599 100644
--- a/lisp/progmodes/verilog-mode.el
+++ b/lisp/progmodes/verilog-mode.el
@@ -14003,7 +14003,7 @@ verilog-sk-primitive
(define-skeleton verilog-sk-task
"Insert a task definition."
()
- > "task " '(verilog-sk-prompt-name) & ?; \n
+ > "task " '(verilog-sk-prompt-name) & ?\; \n
> _ \n
> "begin" \n
> \n
@@ -14013,7 +14013,7 @@ verilog-sk-task
(define-skeleton verilog-sk-function
"Insert a function definition."
()
- > "function [" '(verilog-sk-prompt-width) | -1 '(verilog-sk-prompt-name) ?; \n
+ > "function [" '(verilog-sk-prompt-width) | -1 '(verilog-sk-prompt-name) ?\; \n
> _ \n
> "begin" \n
> \n
@@ -14208,13 +14208,13 @@ verilog-sk-state-machine
'(setq input "state")
> "// State registers for " str | -23 \n
'(setq verilog-sk-state str)
- > "reg [" '(verilog-sk-prompt-width) | -1 verilog-sk-state ", next_" verilog-sk-state ?; \n
+ > "reg [" '(verilog-sk-prompt-width) | -1 verilog-sk-state ", next_" verilog-sk-state ?\; \n
'(setq input nil)
> \n
> "// State FF for " verilog-sk-state \n
> "always @ ( " (read-string "clock:" "posedge clk") " or " (verilog-sk-prompt-reset) " ) begin" \n
> "if ( " verilog-sk-reset " ) " verilog-sk-state " = 0; else" \n
- > verilog-sk-state " = next_" verilog-sk-state ?; \n
+ > verilog-sk-state " = next_" verilog-sk-state ?\; \n
> (- verilog-indent-level-behavioral) "end" (progn (electric-verilog-terminate-line) nil)
> \n
> "// Next State Logic for " verilog-sk-state \n
diff --git a/lisp/skeleton.el b/lisp/skeleton.el
index 92de90c6d9..dbfa87e207 100644
--- a/lisp/skeleton.el
+++ b/lisp/skeleton.el
@@ -487,8 +487,8 @@ skeleton-pair-alist
Elements might be (?\\=` ?\\=` _ \"\\='\\='\"), (?\\( ? _ \" )\") or (?{ \\n > _ \\n ?} >).")
-(defvar skeleton-pair-default-alist '((?( _ ?)) (?\))
- (?[ _ ?]) (?\])
+(defvar skeleton-pair-default-alist '((?\( _ ?\)) (?\))
+ (?\[ _ ?\]) (?\])
(?{ _ ?}) (?\})
(?< _ ?>) (?\>)
(?« _ ?») (?\»)
diff --git a/lisp/woman.el b/lisp/woman.el
index 720fe66be8..aa856c3957 100644
--- a/lisp/woman.el
+++ b/lisp/woman.el
@@ -4420,7 +4420,7 @@ woman2-fc
;; A field is contained between a pair of field delimiter
;; characters and consists of sub-strings separated by padding
;; indicator characters:
- (setq delim (string delim ?[ ?^ delim ?] ?* delim))
+ (setq delim (string delim ?\[ ?^ delim ?\] ?* delim))
(save-excursion
(while (re-search-forward delim end t)
(goto-char (match-beginning 0))
--
2.12.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] Fix all unescaped character literals
2017-05-06 17:17 [PATCH] Fix all unescaped character literals Philipp Stephani
@ 2017-05-07 11:37 ` Philipp
0 siblings, 0 replies; 2+ messages in thread
From: Philipp @ 2017-05-07 11:37 UTC (permalink / raw)
To: emacs-devel; +Cc: Philipp Stephani
[-- Attachment #1: Type: text/plain, Size: 14864 bytes --]
Philipp Stephani <phil07c1@gmail.com> schrieb am Sa., 6. Mai 2017 um
19:17 Uhr:
> ---
> lisp/calendar/timeclock.el | 4 ++--
> lisp/emulation/viper-cmd.el | 2 +-
> lisp/language/japan-util.el | 2 +-
> lisp/leim/quail/cyrillic.el | 8 ++++----
> lisp/mh-e/mh-search.el | 4 ++--
> lisp/nxml/xsd-regexp.el | 2 +-
> lisp/obsolete/complete.el | 2 +-
> lisp/obsolete/vi.el | 4 ++--
> lisp/org/ob-ref.el | 2 +-
> lisp/progmodes/ada-mode.el | 2 +-
> lisp/progmodes/cperl-mode.el | 4 ++--
> lisp/progmodes/gud.el | 8 ++++----
> lisp/progmodes/idlw-shell.el | 4 ++--
> lisp/progmodes/sh-script.el | 4 ++--
> lisp/progmodes/tcl.el | 2 +-
> lisp/progmodes/verilog-mode.el | 8 ++++----
> lisp/skeleton.el | 4 ++--
> lisp/woman.el | 2 +-
> 18 files changed, 34 insertions(+), 34 deletions(-)
>
> diff --git a/lisp/calendar/timeclock.el b/lisp/calendar/timeclock.el
> index f8de084f77..a4709c3b4b 100644
> --- a/lisp/calendar/timeclock.el
> +++ b/lisp/calendar/timeclock.el
> @@ -656,9 +656,9 @@ timeclock-update-mode-line
> (setq timeclock-mode-string
> (propertize
> (format " %c%s%c "
> - (if last-in ?< ?[)
> + (if last-in ?< ?\[)
> (timeclock-seconds-to-string remainder nil t)
> - (if last-in ?> ?]))
> + (if last-in ?> ?\]))
> 'help-echo "timeclock: time remaining"))))
>
> (put 'timeclock-mode-string 'risky-local-variable t)
> diff --git a/lisp/emulation/viper-cmd.el b/lisp/emulation/viper-cmd.el
> index 831b9c1ac2..a697aa7d03 100644
> --- a/lisp/emulation/viper-cmd.el
> +++ b/lisp/emulation/viper-cmd.el
> @@ -90,7 +90,7 @@ viper-charpair-commands
>
> (defconst viper-movement-commands '(?b ?B ?e ?E ?f ?F ?G ?h ?j ?k ?l
> ?H ?M ?L ?n ?t ?T ?w ?W ?$ ?%
> - ?^ ?( ?) ?- ?+ ?| ?{ ?} ?[ ?] ?' ?`
> + ?^ ?\( ?\) ?- ?+ ?| ?{ ?} ?\[ ?\] ?'
> ?`
> ?\; ?, ?0 ?? ?/ ?\ ?\C-m
> space return
> delete backspace
> diff --git a/lisp/language/japan-util.el b/lisp/language/japan-util.el
> index abc8d7d6bc..01cdd8bef9 100644
> --- a/lisp/language/japan-util.el
> +++ b/lisp/language/japan-util.el
> @@ -102,7 +102,7 @@ japanese-symbol-table
> (? $B!' (B ?:) (? $B!( (B ?\;) (? $B!) (B ??) (? $B!* (B ?!) (? $B!+
> (B nil ? (I^ (B) (? $B!, (B nil ? (I_ (B)
> (? $B!- (B ?') (? $B!. (B ?`) (? $B!0 (B ?^) (? $B!2 (B ?_) (? $B!<
> (B ?- ? (I0 (B) (? $B!= (B ?-) (? $B!> (B ?-)
> (? $B!? (B ?/) (? $B!@ (B ?\\) (? $B!A (B ?~) (? $B!C (B ?|) (? $B!F
> (B ?`) (? $B!G (B ?') (? $B!H (B ?\") (? $B!I (B ?\")
> - (?\ $B!J (B ?\() (?\ $B!K (B ?\)) (?\ $B!N (B ?[) (?\ $B!O (B ?]) (?\
> $B!P (B ?{) (?\ $B!Q (B ?})
> + (?\ $B!J (B ?\() (?\ $B!K (B ?\)) (?\ $B!N (B ?\[) (?\ $B!O (B ?\])
> (?\ $B!P (B ?{) (?\ $B!Q (B ?})
> (? $B!R (B ?<) (? $B!S (B ?>) (?\ $B!V (B nil ?\ (I" (B) (?\ $B!W (B
> nil ?\ (I# (B)
> (? $B!\ (B ?+) (? $B!] (B ?-) (? $B!a (B ?=) (? $B!c (B ?<) (? $B!d
> (B ?>)
> (? $B!l (B ?') (? $B!m (B ?\") (? $B!o (B ?\\) (? $B!p (B ?$) (? $B!s
> (B ?%) (? $B!t (B ?#) (? $B!u (B ?&) (? $B!v (B ?*)
> diff --git a/lisp/leim/quail/cyrillic.el b/lisp/leim/quail/cyrillic.el
> index af9f66c47f..600193ddc1 100644
> --- a/lisp/leim/quail/cyrillic.el
> +++ b/lisp/leim/quail/cyrillic.el
> @@ -235,8 +235,8 @@
> ("^" ?:)
> ("&" ??)
> ("*" ?*)
> - ("(" ?()
> - (")" ?))
> + ("(" ?\()
> + (")" ?\))
> ("_" ?_)
> ("+" ?+)
> ("~" ?Ё)
> @@ -789,8 +789,8 @@
> ("^" ?:)
> ("&" ??)
> ("*" ?*)
> - ("(" ?()
> - (")" ?))
> + ("(" ?\()
> + (")" ?\))
> ("_" ?_)
> ("+" ?+)
> ("~" ?')
> diff --git a/lisp/mh-e/mh-search.el b/lisp/mh-e/mh-search.el
> index 099f922a5e..0c2969f5ea 100644
> --- a/lisp/mh-e/mh-search.el
> +++ b/lisp/mh-e/mh-search.el
> @@ -1517,8 +1517,8 @@ mh-index-generate-pretty-name
> (setq string (mh-replace-string "-lbrace" " "))
> (setq string (mh-replace-string "-rbrace" " "))
> (setq string (mh-replace-string "-search" " "))
> - (subst-char-in-region (point-min) (point-max) ?( ? t)
> - (subst-char-in-region (point-min) (point-max) ?) ? t)
> + (subst-char-in-region (point-min) (point-max) ?\( ? t)
> + (subst-char-in-region (point-min) (point-max) ?\) ? t)
> (subst-char-in-region (point-min) (point-max) ?- ? t)
> (goto-char (point-min))
> (while (and (not (eobp)) (memq (char-after) '(? ?\t ?\n ?\r ?_)))
> diff --git a/lisp/nxml/xsd-regexp.el b/lisp/nxml/xsd-regexp.el
> index 6acb1ff9d4..d56960c9fa 100644
> --- a/lisp/nxml/xsd-regexp.el
> +++ b/lisp/nxml/xsd-regexp.el
> @@ -621,7 +621,7 @@ xsdre-single-escape
> (defun xsdre-parse-escape ()
> (let ((ch (car xsdre-current-regexp)))
> (xsdre-advance)
> - (cond ((memq ch '(?\\ ?| ?. ?- ?^ ?* ?+ ?( ?) ?{ ?} ?[ ?])) ch)
> + (cond ((memq ch '(?\\ ?| ?. ?- ?^ ?* ?+ ?\( ?\) ?{ ?} ?\[ ?\])) ch)
> ((eq ch ?r) ?\r)
> ((eq ch ?n) ?\n)
> ((eq ch ?t) ?\t)
> diff --git a/lisp/obsolete/complete.el b/lisp/obsolete/complete.el
> index a6c21bce87..6a7fdc59c2 100644
> --- a/lisp/obsolete/complete.el
> +++ b/lisp/obsolete/complete.el
> @@ -570,7 +570,7 @@ PC-do-completion
> (substring regex (1+ p)))
> p (+ p (length PC-ndelims-regex) (length
> PC-delim-regex)))
> (let ((bump (if (memq (aref regex p)
> - '(?$ ?^ ?\. ?* ?+ ?? ?[ ?] ?\\))
> + '(?$ ?^ ?\. ?* ?+ ?? ?\[ ?\] ?\\))
> -1 0)))
> (setq regex (concat (substring regex 0 (+ p bump))
> PC-ndelims-regex
> diff --git a/lisp/obsolete/vi.el b/lisp/obsolete/vi.el
> index 5b611aa2d0..a7a98d0ca5 100644
> --- a/lisp/obsolete/vi.el
> +++ b/lisp/obsolete/vi.el
> @@ -1444,10 +1444,10 @@ vi-quote-words
> (vi-set-last-change-command 'vi-quote-words arg char)
> (if (not (looking-at "\\<")) (forward-word -1))
> (insert char)
> - (cond ((char-equal char ?[) (setq char ?]))
> + (cond ((char-equal char ?\[) (setq char ?\]))
> ((char-equal char ?{) (setq char ?}))
> ((char-equal char ?<) (setq char ?>))
> - ((char-equal char ?() (setq char ?)))
> + ((char-equal char ?\() (setq char ?\)))
> ((char-equal char ?`) (setq char ?')))
> (vi-end-of-word arg)
> (forward-char 1)
> diff --git a/lisp/org/ob-ref.el b/lisp/org/ob-ref.el
> index 58cc2d96a6..1d26403035 100644
> --- a/lisp/org/ob-ref.el
> +++ b/lisp/org/ob-ref.el
> @@ -133,7 +133,7 @@ org-babel-ref-resolve
> ;; if ref is indexed grab the indices -- beware nested indices
> (when (and (string-match "\\[\\([^\\[]+\\)\\]$" ref)
> (let ((str (substring ref 0 (match-beginning 0))))
> - (= (org-count ?( str) (org-count ?) str))))
> + (= (org-count ?\( str) (org-count ?\) str))))
> (setq index (match-string 1 ref))
> (setq ref (substring ref 0 (match-beginning 0))))
> ;; assign any arguments to pass to source block
> diff --git a/lisp/progmodes/ada-mode.el b/lisp/progmodes/ada-mode.el
> index 10cca6a4a0..ab3ff3aa20 100644
> --- a/lisp/progmodes/ada-mode.el
> +++ b/lisp/progmodes/ada-mode.el
> @@ -1664,7 +1664,7 @@ ada-activate-keys-for-case
> ada-mode-map
> (char-to-string key)
> 'ada-adjust-case-interactive)))
> - '( ?` ?_ ?# ?% ?& ?* ?( ?) ?- ?= ?+
> + '( ?` ?_ ?# ?% ?& ?* ?\( ?\) ?- ?= ?+
> ?| ?\; ?: ?' ?\" ?< ?, ?. ?> ?/ ?\n 32 ?\r )))
>
> (defun ada-loose-case-word (&optional _arg)
> diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el
> index 23ea91fe95..c0f1aaf39d 100644
> --- a/lisp/progmodes/cperl-mode.el
> +++ b/lisp/progmodes/cperl-mode.el
> @@ -2173,8 +2173,8 @@ cperl-electric-paren
> (insert (make-string
> (prefix-numeric-value arg)
> (cdr (assoc last-command-event '((?{ .?})
> - (?[ . ?])
> - (?( . ?))
> + (?\[ . ?\])
> + (?\( . ?\))
> (?< . ?>))))))
> (forward-char (- (prefix-numeric-value arg))))
> (self-insert-command (prefix-numeric-value arg)))))
> diff --git a/lisp/progmodes/gud.el b/lisp/progmodes/gud.el
> index 7ab1442c64..8cb912706f 100644
> --- a/lisp/progmodes/gud.el
> +++ b/lisp/progmodes/gud.el
> @@ -3118,10 +3118,10 @@ gud-expr-compound
> (setq span-start (char-after (- span-start 1)))
> (setq span-end (char-after span-end))
> (cond
> - ((= span-start ?)) t)
> - ((= span-start ?]) t)
> - ((= span-end ?() t)
> - ((= span-end ?[) t)
> + ((= span-start ?\)) t)
> + ((= span-start ?\]) t)
> + ((= span-end ?\() t)
> + ((= span-end ?\[) t)
> (t nil)))
> (t nil))))
>
> diff --git a/lisp/progmodes/idlw-shell.el b/lisp/progmodes/idlw-shell.el
> index 1282f08b07..e7497e8e4f 100644
> --- a/lisp/progmodes/idlw-shell.el
> +++ b/lisp/progmodes/idlw-shell.el
> @@ -4172,8 +4172,8 @@ idlwave-shell-mouse-nop
> ([(control ?t)] ?t idlwave-shell-toggle-toolbar)
> ([(control up)] up idlwave-shell-stack-up)
> ([(control down)] down idlwave-shell-stack-down)
> - ([( ?[)] ?[ idlwave-shell-goto-previous-bp t t)
> - ([( ?])] ?] idlwave-shell-goto-next-bp t t)
> + ([( ?\[)] ?\[ idlwave-shell-goto-previous-bp t t)
> + ([( ?\])] ?\] idlwave-shell-goto-next-bp t t)
> ([(control ?f)] ?f idlwave-shell-window)))
> (mod (and (listp idlwave-shell-debug-modifiers)
> idlwave-shell-debug-modifiers))
> diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el
> index a0bbf55a8f..db965c5a58 100644
> --- a/lisp/progmodes/sh-script.el
> +++ b/lisp/progmodes/sh-script.el
> @@ -599,8 +599,8 @@ sh-mode-map
> map)
> "Keymap used in Shell-Script mode.")
>
> -(defvar sh-skeleton-pair-default-alist '((?( _ ?)) (?\))
> - (?[ ?\s _ ?\s ?]) (?\])
> +(defvar sh-skeleton-pair-default-alist '((?\( _ ?\)) (?\))
> + (?\[ ?\s _ ?\s ?\]) (?\])
> (?{ _ ?}) (?\}))
> "Value to use for `skeleton-pair-default-alist' in Shell-Script mode.")
>
> diff --git a/lisp/progmodes/tcl.el b/lisp/progmodes/tcl.el
> index 2c7ce03665..902a5aace0 100644
> --- a/lisp/progmodes/tcl.el
> +++ b/lisp/progmodes/tcl.el
> @@ -1524,7 +1524,7 @@ tcl-popup-menu
> (defun tcl-quote (string)
> "Quote STRING according to Tcl rules."
> (mapconcat (lambda (char)
> - (if (memq char '(?[ ?] ?{ ?} ?\\ ?\" ?$ ?\s ?\;))
> + (if (memq char '(?\[ ?\] ?{ ?} ?\\ ?\" ?$ ?\s ?\;))
> (concat "\\" (char-to-string char))
> (char-to-string char)))
> string ""))
> diff --git a/lisp/progmodes/verilog-mode.el
> b/lisp/progmodes/verilog-mode.el
> index 9f3bad1c1a..4860ea2599 100644
> --- a/lisp/progmodes/verilog-mode.el
> +++ b/lisp/progmodes/verilog-mode.el
> @@ -14003,7 +14003,7 @@ verilog-sk-primitive
> (define-skeleton verilog-sk-task
> "Insert a task definition."
> ()
> - > "task " '(verilog-sk-prompt-name) & ?; \n
> + > "task " '(verilog-sk-prompt-name) & ?\; \n
> > _ \n
> > "begin" \n
> > \n
> @@ -14013,7 +14013,7 @@ verilog-sk-task
> (define-skeleton verilog-sk-function
> "Insert a function definition."
> ()
> - > "function [" '(verilog-sk-prompt-width) | -1
> '(verilog-sk-prompt-name) ?; \n
> + > "function [" '(verilog-sk-prompt-width) | -1
> '(verilog-sk-prompt-name) ?\; \n
> > _ \n
> > "begin" \n
> > \n
> @@ -14208,13 +14208,13 @@ verilog-sk-state-machine
> '(setq input "state")
> > "// State registers for " str | -23 \n
> '(setq verilog-sk-state str)
> - > "reg [" '(verilog-sk-prompt-width) | -1 verilog-sk-state ", next_"
> verilog-sk-state ?; \n
> + > "reg [" '(verilog-sk-prompt-width) | -1 verilog-sk-state ", next_"
> verilog-sk-state ?\; \n
> '(setq input nil)
> > \n
> > "// State FF for " verilog-sk-state \n
> > "always @ ( " (read-string "clock:" "posedge clk") " or "
> (verilog-sk-prompt-reset) " ) begin" \n
> > "if ( " verilog-sk-reset " ) " verilog-sk-state " = 0; else" \n
> - > verilog-sk-state " = next_" verilog-sk-state ?; \n
> + > verilog-sk-state " = next_" verilog-sk-state ?\; \n
> > (- verilog-indent-level-behavioral) "end" (progn
> (electric-verilog-terminate-line) nil)
> > \n
> > "// Next State Logic for " verilog-sk-state \n
> diff --git a/lisp/skeleton.el b/lisp/skeleton.el
> index 92de90c6d9..dbfa87e207 100644
> --- a/lisp/skeleton.el
> +++ b/lisp/skeleton.el
> @@ -487,8 +487,8 @@ skeleton-pair-alist
>
> Elements might be (?\\=` ?\\=` _ \"\\='\\='\"), (?\\( ? _ \" )\") or (?{
> \\n > _ \\n ?} >).")
>
> -(defvar skeleton-pair-default-alist '((?( _ ?)) (?\))
> - (?[ _ ?]) (?\])
> +(defvar skeleton-pair-default-alist '((?\( _ ?\)) (?\))
> + (?\[ _ ?\]) (?\])
> (?{ _ ?}) (?\})
> (?< _ ?>) (?\>)
> (?« _ ?») (?\»)
> diff --git a/lisp/woman.el b/lisp/woman.el
> index 720fe66be8..aa856c3957 100644
> --- a/lisp/woman.el
> +++ b/lisp/woman.el
> @@ -4420,7 +4420,7 @@ woman2-fc
> ;; A field is contained between a pair of field delimiter
> ;; characters and consists of sub-strings separated by padding
> ;; indicator characters:
> - (setq delim (string delim ?[ ?^ delim ?] ?* delim))
> + (setq delim (string delim ?\[ ?^ delim ?\] ?* delim))
> (save-excursion
> (while (re-search-forward delim end t)
> (goto-char (match-beginning 0))
> --
> 2.12.2
>
>
Because this patch is trivial, I've installed it as 3c4c8ca06e.
[-- Attachment #2: Type: text/html, Size: 17961 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-05-07 11:37 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-06 17:17 [PATCH] Fix all unescaped character literals Philipp Stephani
2017-05-07 11:37 ` Philipp
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).