Custom Query (1030 matches)
Results (727 - 729 of 1030)
| Ticket | Resolution | Summary | Owner | Reporter |
|---|---|---|---|---|
| #1319 | fixed | Unexpected behaviour of dynamic extent variable | ||
| Description |
Using Clozure Common Lisp-Version 1.11-RC1-r16620 (DarwinX8664) to define functions within function groups, the functions defined must have unique names that can be traced back to the group in which they were defined. In the code snippet below the macro defop-environment sets up a name as a special variable that is used in defop, partly to get the intended name, partly to ensure defop was used within a defop-environment. The code below is as short as I could make it. It works in Clisp and ABCL but does not work in CCL (or SBCL for that matter). (unless (find-package :wondering)
(defpackage wondering
(:use :cl)))
(in-package :wondering)
(defvar *environments*
(make-hash-table :test 'eq))
(let ((defop-prefix "OP-FN%"))
(defmacro defop-environment (name &rest defops)
"(defop-environment <name> &rest <defops>)
Define a new operator environment with name <name> and operators
defined by <defops>."
(let ((new-table (make-hash-table :test 'eq)))
`(let ((*name-prefix* ,(concatenate 'string defop-prefix (string name) "%"))
(*operator-table* ,new-table))
(declare (special *environments* *operator-table* *name-prefix*))
(format *trace-output* "Before defop *name-prefix* ~S~%" *name-prefix*)
,@defops
(setf (gethash ',name *environments*) *operator-table*)
',name)))
(defmacro defop (name lambda-list &body body)
"Define an operator. Error unless used within a
defop-environment."
(declare (special *name-prefix*))
(format *trace-output* "(defwalk ~A ~A~% ~{~S~})~%"name lambda-list body)
(unless (and (boundp '*name-prefix*) (stringp *name-prefix*))
(error "Only use defop inside a defop-environmemt."))
(let ((fname (values (intern
(concatenate 'string *name-prefix*
(string (if (symbolp name) name (car name))))
*package*))))
(format *trace-output* "In defop *name-prefix* ~S, fname: ~S~%"
*name-prefix* fname)
`(locally
(declare (special *operator-table*))
(defun ,fname ,lambda-list ,@body)
(setf (gethash ',name *operator-table*) ',fname)
',name))))
Evaluating (defop-environment env0 (defop fn0 (x y) (fn x y))) directly makes CCL unhappy:
Could you please look into this? A workaround is also very welcome. Thank you very much, Ernst van Waning |
|||
| #1320 | fixed | I/O timeout arguments for TCP sockets are interpreted as milliseconds | ||
| Description |
(copied from openmcl-devel, see also #1247 as it seems to be related) Hi folks, (in Clozure CL 1.10) could there be a bug in `l1-sockets.lisp:859-860', where timeout values (supposedly in seconds) are not converted to the proper millisecond values used by PROCESS-INPUT-WAIT (`l1-streams.lisp:5449')? The documentation says (emphasis added):
I have not followed the rabbit hole to full length, but I am getting I/O timeout conditions on streams with i/o-timeout == 10 way before 10 seconds. It being actually interpreted as 10 milliseconds would make sense. Try this to verify (this blocks for 10 seconds when I run it):
Regards, max |
|||
| #1330 | fixed | ~~ does not work properly in FORMAT | ||
| Description |
|
|||
