Custom Query (1030 matches)

Filters
 
Or
 
  
 
Columns

Show under each result:


Results (265 - 267 of 1030)

Ticket Resolution Summary Owner Reporter
#1064 fixed reduce maphash consing Martin Brooks
Description

with-hash-table-iterator in file macros.lisp results in what appears to be unnecessary consing.

Consing is reduced by adding ,state to the list of dynamic-extent declarations, as shown below.

(defmacro with-hash-table-iterator ((mname hash-table) &body body)

"WITH-HASH-TABLE-ITERATOR ((function hash-table) &body body)

provides a method of manually looping over the elements of a hash-table. FUNCTION is bound to a generator-macro that, within the scope of the invocation, returns one or three values. The first value tells whether any objects remain in the hash table. When the first value is non-NIL, the second and third values are the key and the value of the next object."

(let* ((hash (gensym))

(keys (gensym)) (values (gensym)) (count (gensym)) (state (gensym)))

`(let* ((,hash ,hash-table)

(,count (hash-table-count ,hash)) (,keys (make-array ,count)) (,values (make-array ,count)) (,state (vector ,hash 0 ,keys ,values (enumerate-hash-keys-and-values ,hash ,keys ,values))))

(declare (dynamic-extent ,keys ,values ,state)

(fixnum ,count))

(macrolet ((,mname () `(next-hash-table-iteration-1 ,',state)))

,@body))))

#1066 duplicate improve coercion to difficult complex types Bike
Description
Welcome to Clozure Common Lisp Version 1.8  (LinuxX8632)!
? (deftype foo () '(complex double-float))
FOO
? (coerce #c(2 4) '(complex double-float))
#C(2.0D0 4.0D0)
? (coerce #c(2 4) 'foo)
> Error: value #C(2 4) is not of the expected type REAL.
> While executing: COMPLEX, in process listener(1).
> Type :POP to abort, :R for a list of available restarts.
> Type :? for other options.
1 > 

Basically this happens because coerce-to-complex works on the literal type specifier instead of the canonicalized ctype. I've included a small patch to remedy this.

#1067 invalid Issue with read-time conditionalization facility Roger
Description

Hi,

I have installed the latest ccl:

$ uname -a
Darwin localbox 11.4.2 Darwin Kernel Version 11.4.2: Thu Aug 23 16:25:48 PDT 2012; root:xnu-1699.32.7~1/RELEASE_X86_64 x86_64

$ /usr/local/ccl-1.9/dx86cl64
Welcome to Clozure Common Lisp Version 1.9-r15759  (DarwinX8664)!

And I'm having issues with conditional read time (#+) working incorrectly. You can reproduce the issues trying to load nibbles or ironclad:

nibbles:

$ /usr/local/ccl-1.9/dx86cl64
(quicklWelcome to Clozure Common Lisp Version 1.9-r15759  (DarwinX8664)!
? (quicklisp:quickload "nibbles" :verbose t)
To load "nibbles":
  Load 1 ASDF system:
    nibbles
; Loading "nibbles"
Read error between positions 70 and 91 in /Users/rogersm/quicklisp/dists/quicklisp/software/nibbles-20121125-git/sbcl-opt/nib-tran.lisp.
> Error: There is no package named "SB-C" .
> While executing: CCL::%PARSE-TOKEN, in process listener(1).
> Type :GO to continue, :POP to abort, :R for a list of available restarts.
> If continued: Retry finding package with name "SB-C".


> Type :? for other options.

A possible solution is to apply this patch to nibbles package:

sbcl-opt/nib-tran.lisp
@@ -2,8 +2,9 @@
 
 (cl:in-package :nibbles)
 
-#+sbcl (progn
+#+sbcl
 
+(progn
 (sb-c:deftransform %check-bound ((vector bound offset n-bytes)
 				 ((simple-array (unsigned-byte 8) (*)) index
 				  (and fixnum sb-vm:word)


But nowhere in Hyperspec says a return carriage should be added.

ironclad:

$ /usr/local/ccl-1.9/dx86cl64
(quicklWelcome to Clozure Common Lisp Version 1.9-r15759  (DarwinX8664)!
? (quicklisp:quickload "ironclad" :verbose t)
To load "ironclad":
  Load 1 ASDF system:
    ironclad
; Loading "ironclad"
Read error between positions 70 and 91 in /Users/rogersm/quicklisp/dists/quicklisp/software/nibbles-20121125-git/sbcl-opt/nib-tran.lisp.
> Error: There is no package named "SB-C" .
> While executing: CCL::%PARSE-TOKEN, in process listener(1).
> Type :GO to continue, :POP to abort, :R for a list of available restarts.
> If continued: Retry finding package with name "SB-C".
> Type :? for other options.

Both issues do not occur in:

$ /usr/local/ccl-1.8/dx86cl64
Welcome to Clozure Common Lisp Version 1.8-r15286M  (DarwinX8664)!
Batch Modify
Note: See TracBatchModify for help on using batch modify.
Note: See TracQuery for help on using queries.