Common Lisp Dynamic Type Checking

#202204251732 provides some facilities for type checking in runtime. This includes check-type. The following example shows a use case:

(defun adder (n1 n2)
  (check-type n1 number) ; check if n1 == number
  (check-type n2 number) ; check if n2 == number
  (+ n1 n2))
Links to this page
#lisp #type-check