Function: calc-num-prefix

calc-num-prefix is an autoloaded, interactive and byte-compiled function defined in calc-stuff.el.gz.

Signature

(calc-num-prefix N)

Documentation

Use the number at the top of stack as the numeric prefix for the next command.

With a prefix, push that prefix as a number onto the stack.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/calc/calc-stuff.el.gz
(defun calc-num-prefix (n)
  "Use the number at the top of stack as the numeric prefix for the next command.
With a prefix, push that prefix as a number onto the stack."
  (interactive "P")
  (calc-wrapper
   (if n
       (calc-enter-result 0 "" (prefix-numeric-value n))
     (let ((num (calc-top 1)))
       (if (math-messy-integerp num)
	   (setq num (math-trunc num)))
       (or (integerp num)
	   (error "Argument must be a small integer"))
       (calc-pop-stack 1)
       (setq prefix-arg num)
       (message "%d-" num)))))    ; a (lame) simulation of the real thing...