]> code.delx.au - gnu-emacs/blobdiff - lisp/simple.el
Merge from trunk
[gnu-emacs] / lisp / simple.el
index a2dda5f04d204abb993672e3500d0c5284a73732..4549a0bb336867048a1125245e49dc2b33cc81f0 100644 (file)
@@ -998,7 +998,7 @@ When called interactively, the word count is printed in echo area."
         (goto-char (point-min))
         (while (forward-word 1)
           (setq count (1+ count)))))
-    (if (interactive-p)
+    (if (called-interactively-p 'interactive)
         (message "Region has %d words" count))
     count))
 
@@ -1218,12 +1218,12 @@ this command arranges for all errors to enter the debugger."
         current-prefix-arg))
 
   (if (null eval-expression-debug-on-error)
-      (setq values (cons (eval eval-expression-arg) values))
+      (push (eval eval-expression-arg lexical-binding) values)
     (let ((old-value (make-symbol "t")) new-value)
       ;; Bind debug-on-error to something unique so that we can
       ;; detect when evaled code changes it.
       (let ((debug-on-error old-value))
-       (setq values (cons (eval eval-expression-arg) values))
+       (push (eval eval-expression-arg lexical-binding) values)
        (setq new-value debug-on-error))
       ;; If evaled code has changed the value of debug-on-error,
       ;; propagate that change to the global binding.
@@ -6652,6 +6652,7 @@ saving the value of `buffer-invisibility-spec' and setting it to nil."
 \f
 ;; Partial application of functions (similar to "currying").
 ;; This function is here rather than in subr.el because it uses CL.
+;; (defalias 'apply-partially #'curry)
 (defun apply-partially (fun &rest args)
   "Return a function that is a partial application of FUN to ARGS.
 ARGS is a list of the first N arguments to pass to FUN.