Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Type error during load fast-http using quicklisp. #35

Open
SFurnace opened this issue Jan 13, 2018 · 1 comment
Open

Type error during load fast-http using quicklisp. #35

SFurnace opened this issue Jan 13, 2018 · 1 comment

Comments

@SFurnace
Copy link

SFurnace commented Jan 13, 2018

I got this when I load this system using quicklisp.

Error: Variable +TOKENS+ was declared type (SIMPLE-ARRAY CHARACTER (128)) but is being set to value #(#\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\Null #\! #\Null #\# #\$ #\% #\& #\' ...).
   1 (continue) Try loading ......

Actually, according to CLHS, #( and ) are used to notate a simple vector., and the compound type specifiers derive from simple-vector is the same as (simple-array t (size)). I think this is the reason why an error was signaled.

My lisp implementation is LispWorks 7.1, and this bug can be fixed by using coerceon +tokens+ and +unhex+ like this:

(define-constant +tokens+
                 (coerce #( #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul
                            #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul
                            #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul
                            #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul
                            #\Nul   #\!   #\Nul   #\#    #\$    #\%    #\&    #\'
                            #\Nul  #\Nul   #\*    #\+   #\Nul    #\-   #\.   #\Nul
                            #\0    #\1    #\2    #\3    #\4    #\5    #\6    #\7
                            #\8    #\9   #\Nul  #\Nul  #\Nul  #\Nul  #\Nul  #\Nul
                            #\Nul   #\a    #\b    #\c    #\d    #\e    #\f    #\g
                            #\h    #\i    #\j    #\k    #\l    #\m    #\n    #\o
                            #\p    #\q    #\r    #\s    #\t    #\u    #\v    #\w
                            #\x    #\y    #\z   #\Nul  #\Nul  #\Nul   #\^    #\_
                            #\`    #\a    #\b    #\c    #\d    #\e    #\f    #\g
                            #\h    #\i    #\j    #\k    #\l    #\m    #\n    #\o
                            #\p    #\q    #\r    #\s    #\t    #\u    #\v    #\w
                            #\x    #\y    #\z   #\Nul   #\|   #\Nul   #\~   #\Nul ) 
                         '(simple-array character (128)))
                 :test 'equalp)
@paulvaneecke
Copy link

I had the same problem, but this seems to be fixed now, not only in the repository version, but also on in the quicklisp version :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants