[Ecls-list] Bug in argument checking based on function proclamation

Gabriel Dos Reis gdr at integrable-solutions.net
Tue Jun 29 00:12:04 UTC 2010


On Mon, Jun 28, 2010 at 2:46 PM, Juan Jose Garcia-Ripoll
<juanjose.garciaripoll at googlemail.com> wrote:
> * Proclamations are also used to deduce the type of a function's arguments
> and create argument type checks.
>

Hi Juanjo,

  The function arguments checking seems to have a bug.  The attached
testcase (distilled from OpenAxiom) produces the following warnings:

> (compile-file "pbug.lisp")

;;; Loading #P"/usr/local/lib/ecl-10.4.2/cmp.fas"
;;;
;;; Compiling pbug.lisp.
;;; OPTIMIZE levels: Safety=2, Space=0, Speed=3, Debug=0
;;;
;;; Compiling (DEFUN BEGIN-DOLLAR-P ...).
;;; Note:
;;;   in file pbug.lisp, position 55
;;;   at (DEFUN BEGIN-DOLLAR-P ...)
;;;   In function BEGIN-DOLLAR-P, checking types of arguments X.
;;; Note:
;;;   in file pbug.lisp, position 55
;;;   at (DEFUN BEGIN-DOLLAR-P ...)
;;;   Unknown type (T). Assuming it is T.
;;; Compiling (DEFUN COMP-FLUIDIZE ...).
;;; Warning:
;;;   in file pbug.lisp, position 123
;;;   at (DEFUN COMP-FLUIDIZE ...)
;;;   ! Too few arguments for proclaimed function BEGIN-DOLLAR-P
;;; End of Pass 1.
;;; Note:
;;;   Refusing to propagate FUNCALL
;;; Note:
;;;   Refusing to propagate C-INLINE
;;; Warning:
;;;   ! Too few arguments for proclaimed function BEGIN-DOLLAR-P


1. The argument-type in the function proclamation is simple enough
    that ECL should not be confused.

2. ECL pretends that there are too few arguments for proclaimed
    BEGIN-DOLLAR-P.  Yet, the function was proclaimed to be
    of arity 1, and there is exactly one argument supplied in the call.

What are the notes about propagating FUNCALL and C-INLINE about?

-- Gaby
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pbug.lisp
Type: application/octet-stream
Size: 206 bytes
Desc: not available
URL: <https://mailman.common-lisp.net/pipermail/ecl-devel/attachments/20100628/d2b34fc4/attachment.obj>


More information about the ecl-devel mailing list