repair for define-cpointer-type
This commit is contained in:
parent
762994654c
commit
e92b07728f
|
@ -1021,6 +1021,13 @@
|
|||
(define-cpointer-type _foo)
|
||||
(test 'foo? object-name foo?)
|
||||
|
||||
(define-cpointer-type _also_foo #f #f (lambda (ptr)
|
||||
(cpointer-push-tag! ptr 'extra)
|
||||
ptr))
|
||||
(let ([p (cast (malloc 16) _pointer _also_foo)])
|
||||
(test #t also_foo? p)
|
||||
(test #t cpointer-has-tag? p 'extra))
|
||||
|
||||
;; ----------------------------------------
|
||||
;; Test JIT inlining
|
||||
|
||||
|
|
|
@ -1356,7 +1356,7 @@
|
|||
[(_ _TYPE #:tag the-tag) #'(define-cpointer-type _TYPE #f #f #f #:tag the-tag)]
|
||||
[(_ _TYPE ptr-type) #'(define-cpointer-type _TYPE ptr-type #f #f #:tag #f)]
|
||||
[(_ _TYPE ptr-type #:tag the-tag) #'(define-cpointer-type _TYPE ptr-type #f #f #:tag the-tag)]
|
||||
[(_ _TYPE ptr-type scheme->c c->scheme) #'(define-cpointer-type _TYPE ptr-type #f #f #:tag #f)]
|
||||
[(_ _TYPE ptr-type scheme->c c->scheme) #'(define-cpointer-type _TYPE ptr-type scheme->c c->scheme #:tag #f)]
|
||||
[(_ _TYPE ptr-type scheme->c c->scheme #:tag the-tag)
|
||||
(and (identifier? #'_TYPE)
|
||||
(regexp-match #rx"^_.+" (symbol->string (syntax-e #'_TYPE))))
|
||||
|
|
Loading…
Reference in New Issue
Block a user