Function: calc-graph-lookup

calc-graph-lookup is a byte-compiled function defined in calc-graph.el.gz.

Signature

(calc-graph-lookup THING)

Source Code

;; Defined in /usr/src/emacs/lisp/calc/calc-graph.el.gz
(defun calc-graph-lookup (thing)
  (if (and (eq (car-safe thing) 'var)
	   (calc-var-value (nth 2 thing)))
      thing
    (let ((found (assoc thing calc-graph-var-cache)))
      (or found
	  (let ((varname (concat "PlotData"
                                 (int-to-string
                                  (1+ (length calc-graph-var-cache)))))
		var)
            (setq var (list 'var (intern varname)
			    (intern (concat "var-" varname)))
		  found (cons thing var)
		  calc-graph-var-cache (cons found calc-graph-var-cache))
	    (set (nth 2 var) thing)))
      (cdr found))))