The value
-2
is not of type
(UNSIGNED-BYTE 8)
[Condition of type TYPE-ERROR]
Restarts:
0: [RETRY] Retry SLIME REPL evaluation request.
1: [*ABORT] Return to SLIME's top level.
2: [ABORT] abort thread (#<THREAD "repl-thread" RUNNING {10018A0173}>)
Backtrace:
0: (SB-IMPL::OUTPUT-UNSIGNED-BYTE-FULL-BUFFERED #<SB-SYS:FD-STREAM for "file /tmp/nff.npy" {1008E21FB3}> -2)
1: (WRITE-BYTE -2 #<SB-SYS:FD-STREAM for "file /tmp/nff.npy" {1008E21FB3}>)
2: (NUMPY-FILE-FORMAT:STORE-ARRAY #(-2 -1 0 1) "/tmp/nff.npy")
Also,
CL-USER> (subtypep '(signed-byte 8)
'(signed-byte *))
T
T
CL-USER> (subtypep '(array (signed-byte 8))
'(array (signed-byte *)))
NIL
T
[Update] One fix is to use the following:
CL-USER> (subtypep (array-element-type array)
'(signed-byte *))
T
T
Is there a better fix - or regression tests to check if something breaks?
I just noted the following on CCL and SBCL:
Due to this,
causes the following error:
Also,
[Update] One fix is to use the following:
Is there a better fix - or regression tests to check if something breaks?