Commit a17f9e55 authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

*** empty log message ***

parent 29975121
...@@ -187,21 +187,17 @@ The defun marked is the one that contains point or follows point." ...@@ -187,21 +187,17 @@ The defun marked is the one that contains point or follows point."
"Put parentheses around next ARG sexps. Leave point after open-paren. "Put parentheses around next ARG sexps. Leave point after open-paren.
No argument is equivalent to zero: just insert () and leave point between." No argument is equivalent to zero: just insert () and leave point between."
(interactive "P") (interactive "P")
(if arg (skip-chars-forward " \t")) (if arg (setq arg (prefix-numeric-value arg))
(setq arg 0))
(or (eq arg 0) (skip-chars-forward " \t"))
(and (memq (char-syntax (preceding-char)) '(?w ?_ ?\) )) (and (memq (char-syntax (preceding-char)) '(?w ?_ ?\) ))
(insert " ")) (insert " "))
; (or (memq (char-syntax (preceding-char)) '(?\ ?> ?\( ))
; (insert " ")))
(insert ?\() (insert ?\()
(save-excursion (save-excursion
(if arg (or (eq arg 0) (forward-sexp arg))
(forward-sexp (prefix-numeric-value arg)))
(insert ?\)) (insert ?\))
; (or (memq (char-syntax (following-char)) '(?\ ?> ?\( )) (and (memq (char-syntax (following-char)) '(?w ?_ ?\( ))
; (insert " ")) (insert " "))))
(and (memq (char-syntax (following-char)) '(?w ?_ ?\( ))
(insert " "))
))
(defun move-past-close-and-reindent () (defun move-past-close-and-reindent ()
"Move past next `)', delete indentation before it, then indent after it." "Move past next `)', delete indentation before it, then indent after it."
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment