changeset 62717:5aa3c60503e2

(calc-user-define-edit): Don't find substring of nil.
author Jay Belanger <jay.p.belanger@gmail.com>
date Thu, 26 May 2005 12:24:05 +0000
parents 05f48d9c5aed
children d00be6e651cd
files lisp/calc/calc-prog.el
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/calc/calc-prog.el	Thu May 26 12:20:21 2005 +0000
+++ b/lisp/calc/calc-prog.el	Thu May 26 12:24:05 2005 +0000
@@ -702,7 +702,7 @@
 			       (get func 'calc-user-defn)))
                     (kys (concat "z" (char-to-string (car def))))
                     (intcmd (symbol-name (cdr def)))
-                    (algcmd (substring (symbol-name func) 9)))
+                    (algcmd (if func (substring (symbol-name func) 9) "")))
 	       (if (and defn (calc-valid-formula-func func))
 		   (let ((niceexpr (math-format-nice-expr defn (frame-width))))
 		     (calc-wrapper