bug-guile
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#12465: generalized-vector->list and shared arrays


From: Daniel Llorens
Subject: bug#12465: generalized-vector->list and shared arrays
Date: Tue, 18 Sep 2012 16:15:36 +0200

        
There's a bug with generalized-vector->list and shared arrays. I have seen this 
kind of bug before, I'm not sure if it wasn't fixed last time or it has 
resurfaced somehow.

GNU Guile 2.0.6
Copyright (C) 1995-2012 Free Software Foundation, Inc.

Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'.
This program is free software, and you are welcome to redistribute it
under certain conditions; type `,show c' for details.

Enter `,help' for help.
scheme@(guile-user)> (define a #2((1 2) (3 4)))
scheme@(guile-user)> (define b (make-shared-array a (lambda (j) (list 1 j)) 2))
scheme@(guile-user)> b
$1 = #(3 4)
scheme@(guile-user)> (generalized-vector->list b)
$2 = (1 2)
scheme@(guile-user)> (define c (make-shared-array a (lambda (i) (list i 1)) 2))
scheme@(guile-user)> c
$3 = #(2 4)
scheme@(guile-user)> (generalized-vector->list c)
ERROR: In procedure generalized-vector->list:
ERROR: In procedure vector-handle-ref: Value out of range: 18446744073709551615

Entering a new prompt.  Type `,bt' for a backtrace or `,q' to continue.
scheme@(guile-user) [1]> 

However generalized-vector-ref seems to work correctly.

I'm posting to guile-devel with my proposed ‘solution’.

Regards,

        Daniel






reply via email to

[Prev in Thread] Current Thread [Next in Thread]