Some temporary guile hacks added

This commit is contained in:
retropikzel 2024-06-22 08:45:09 +03:00
parent 2752cc198d
commit 064ca3d668
1 changed files with 7 additions and 9 deletions

View File

@ -106,7 +106,6 @@
((equal? native-type uint32) (bytevector-u32-set! p offset value (native-endianness)))
((equal? native-type int64) (bytevector-s64-set! p offset value (native-endianness)))
((equal? native-type uint64) (bytevector-u64-set! p offset value (native-endianness)))
((equal? native-type char) (bytevector-u8-set! p offset value))
((equal? native-type short) (bytevector-s8-set! p offset value))
((equal? native-type unsigned-short) (bytevector-u8-set! p offset value))
((equal? native-type int) (bytevector-sint-set! p offset value (native-endianness) (pffi-size-of type)))
@ -129,16 +128,15 @@
((equal? native-type uint32) (bytevector-u32-ref p offset (native-endianness)))
((equal? native-type int64) (bytevector-s64-ref p offset (native-endianness)))
((equal? native-type uint64) (bytevector-u64-ref p offset (native-endianness)))
((equal? native-type char) (bytevector-u8-ref p offset value))
((equal? native-type short) (bytevector-s8-ref p offset value))
((equal? native-type unsigned-short) (bytevector-u8-ref p offset value))
((equal? native-type short) (bytevector-s8-ref p offset))
((equal? native-type unsigned-short) (bytevector-u8-ref p offset))
((equal? native-type int) (bytevector-sint-ref p offset (native-endianness) (pffi-size-of type)))
((equal? native-type unsigned-int) (bytevector-uint-ref p offset (native-endianness) (pffi-size-of type)))
((equal? native-type long) (bytevector-s64-ref p offset value (native-endianness)))
((equal? native-type unsigned-long) (bytevector-u64-ref p offset value (native-endianness)))
((equal? native-type float) (bytevector-u64-ref p offset value (native-endianness)))
((equal? native-type double) (bytevector-u64-ref p offset value (native-endianness)))
((equal? native-type '*) (bytevector-sint-ref p offset value (native-endianness) (pffi-size-of type)))))))
((equal? native-type long) (bytevector-s64-ref p offset (native-endianness)))
((equal? native-type unsigned-long) (bytevector-u64-ref p offset (native-endianness)))
((equal? native-type float) (bytevector-u64-ref p offset (native-endianness)))
((equal? native-type double) (bytevector-u64-ref p offset (native-endianness)))
((equal? native-type '*) (bytevector-sint-ref p offset (native-endianness) (pffi-size-of type)))))))
(define pffi-pointer-deref
(lambda (pointer)