Custom Query (1030 matches)
Results (283 - 285 of 1030)
| Ticket | Resolution | Summary | Owner | Reporter |
|---|---|---|---|---|
| #1084 | fixed | deficient error reporting in flet on bad lambda-list | ||
| Description |
cl-user> (compile-file #P"~/test-flet.lisp")
#P"/home/pjb/test-flet.lx64fsl"
nil
nil
cl-user> (cat #P"~/test-flet.lisp")
(defun f (z)
(flet ((g (x) (list x x))
(u z))
(g z)))
; No value
cl-user>
The fact that the "lambda-list" for u is an atom should signal a program-error. CLHS flet says: lambda-list---a lambda list; for flet and labels, it is an ordinary lambda list; and CLHS 3.4.1 says: The syntax for ordinary lambda lists is as follows:
lambda-list::= (var*
[&optional {var | (var [init-form [supplied-p-parameter]])}*]
[&rest var]
[&key {var | ({var | (keyword-name var)} [init-form [supplied-p-parameter]])}* [&allow-other-keys]]
[&aux {var | (var [init-form])}*])
so lambda-list for flet and labels cannot be an atom. And in the case where I found this, u was also a global function, so perhaps this could be tested by the compiler to add a hint in the error message that perhaps the form was intented to be in the body of the flet. |
|||
| #1216 | fixed | decode-float broken | ||
| Description |
decode-float seems to be broken, it returns some random 3rd value instead of the sign: [LinuxArm32, Odroid U3] Welcome to Clozure Common Lisp Version 1.10-dev-r16155M-trunk (LinuxARM32)! ? (decode-float pi) 0.7853981633974483D0 2 6.441148769597133D-232 Similarly on Windows X86 32Bit: Welcome to Clozure Common Lisp Version 1.10-dev-r16103-trunk (WindowsX8632)! ? (decode-float pi) 0.7853981633974483D0 2 59757440 Windows X86 64Bit works ok: Welcome to Clozure Common Lisp Version 1.10-dev (WindowsX8664)! ? (decode-float pi) 0.7853981633974483D0 2 1.0D0 Same behavior with single-floats. |
|||
| #458 | fixed | decode-float and negative arguments | ||
| Description |
According to the spec, the following should be true for any floating-point number (multiple-value-bind (signif expon sign)
(decode-float f)
(* (scale-float signif expon) sign))
== f
http://www.lispworks.com/documentation/HyperSpec/Body/f_dec_fl.htm
If CCL> (decode-float -1.0d0) -0.5D0 1 -1.0D0 and thus: CCL> (let ((f -1.0d0))
(multiple-value-bind (signif expon sign)
(decode-float f)
(* (scale-float signif expon) sign)))
1.0D0
Probably we should ensure that the significand is non-negative in all cases. |
|||
