Function: calc-change-current-selection
calc-change-current-selection is a byte-compiled function defined in
calc-sel.el.gz.
Signature
(calc-change-current-selection SUB-EXPR)
Source Code
;; Defined in /usr/src/emacs/lisp/calc/calc-sel.el.gz
(defun calc-change-current-selection (sub-expr)
(or (eq sub-expr (nth 2 calc-selection-cache-entry))
(let ((calc-prepared-composition calc-selection-cache-comp)
(buffer-read-only nil)
top)
(calc-set-command-flag 'renum-stack)
(setcar (nthcdr 2 calc-selection-cache-entry) sub-expr)
(calc-cursor-stack-index calc-selection-cache-num)
(setq top (point))
(calc-cursor-stack-index (1- calc-selection-cache-num))
(delete-region top (point))
(let ((calc-selection-cache-default-entry calc-selection-cache-entry))
(insert (math-format-stack-value calc-selection-cache-entry)
"\n")))))