Function: byte-compile--check-arity-bytecode

byte-compile--check-arity-bytecode is a byte-compiled function defined in bytecomp.el.gz.

Signature

(byte-compile--check-arity-bytecode FORM BYTECODE)

Documentation

Check that the call in FORM matches that allowed by BYTECODE.

Source Code

;; Defined in /usr/src/emacs/lisp/emacs-lisp/bytecomp.el.gz
(defun byte-compile--check-arity-bytecode (form bytecode)
  "Check that the call in FORM matches that allowed by BYTECODE."
  (when (byte-code-function-p bytecode)
    (let* ((actual-args (length (cdr form)))
           (arity (func-arity bytecode))
           (min-args (car arity))
           (max-args (and (numberp (cdr arity)) (cdr arity))))
      (when (or (< actual-args min-args)
                (and max-args (> actual-args max-args)))
        (byte-compile-emit-callargs-warn
         (car form) actual-args min-args max-args)))))