/[emacs]/emacs/lisp/calc/calc-rewr.el
ViewVC logotype

Diff of /emacs/lisp/calc/calc-rewr.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.6.4.1 by handa, Fri Apr 16 12:50:11 2004 UTC revision 1.6.4.2 by miles, Wed Oct 27 05:42:03 2004 UTC
# Line 143  Line 143 
143       (calc-pop-push-record-list n "rwrt" (list expr)))       (calc-pop-push-record-list n "rwrt" (list expr)))
144     (calc-handle-whys)))     (calc-handle-whys)))
145    
146  (defun calc-match (pat)  (defun calc-match (pat &optional interactive)
147    (interactive "sPattern: \n")    (interactive "sPattern: \np")
148    (calc-slow-wrapper    (calc-slow-wrapper
149     (let (n expr)     (let (n expr)
150       (if (or (null pat) (equal pat "") (equal pat "$"))       (if (or (null pat) (equal pat "") (equal pat "$"))
151           (setq expr (calc-top-n 2)           (setq expr (calc-top-n 2)
152                 pat (calc-top-n 1)                 pat (calc-top-n 1)
153                 n 2)                 n 2)
154         (if (interactive-p) (setq calc-previous-alg-entry pat))         (if interactive (setq calc-previous-alg-entry pat))
155         (setq pat (if (stringp pat) (math-read-expr pat) pat))         (setq pat (if (stringp pat) (math-read-expr pat) pat))
156         (if (eq (car-safe pat) 'error)         (if (eq (car-safe pat) 'error)
157             (error "Bad format in expression: %s" (nth 1 pat)))             (error "Bad format in expression: %s" (nth 1 pat)))

Legend:
Removed from v.1.6.4.1  
changed lines
  Added in v.1.6.4.2

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26