From 2e4daa0e05fd40231760e7a820a140ee77868b21 Mon Sep 17 00:00:00 2001 From: Jay Belanger Date: Mon, 19 May 2008 02:42:28 +0000 Subject: [PATCH] (calc-get-register): Fix problem when the Calc register is empty. --- lisp/calc/calc-yank.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lisp/calc/calc-yank.el b/lisp/calc/calc-yank.el index e1e83abe70c..65bec46db8e 100644 --- a/lisp/calc/calc-yank.el +++ b/lisp/calc/calc-yank.el @@ -156,9 +156,9 @@ in which case either return the contents of the Emacs register (if it is text) or `nil'." (let ((cval (cdr (assq reg calc-register-alist))) (val (cdr (assq reg register-alist)))) - (if (and (stringp (car cval)) - (stringp val)) - (if (string= (car cval) val) + (if (stringp val) + (if (and (stringp (car cval)) + (string= (car cval) val)) (cdr cval) val)))) -- 2.11.4.GIT