mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-24 12:35:05 +02:00
Issue #370 - bignum support for c->scm, WIP thread data
This commit is contained in:
parent
51e73fcbd3
commit
3bd18880a4
1 changed files with 11 additions and 0 deletions
|
@ -119,6 +119,8 @@
|
||||||
(string-append "opaque_ptr(" ,code ")"))
|
(string-append "opaque_ptr(" ,code ")"))
|
||||||
((c-void)
|
((c-void)
|
||||||
"Cyc_VOID")
|
"Cyc_VOID")
|
||||||
|
((data)
|
||||||
|
"data")
|
||||||
(else
|
(else
|
||||||
(error "scm->c unable to convert scheme object of type " ,type)))))))
|
(error "scm->c unable to convert scheme object of type " ,type)))))))
|
||||||
|
|
||||||
|
@ -151,6 +153,13 @@
|
||||||
"make_double(" var ", " ,code ");")
|
"make_double(" var ", " ,code ");")
|
||||||
(string-append "&" var)
|
(string-append "&" var)
|
||||||
)))
|
)))
|
||||||
|
((bignum bigint)
|
||||||
|
(let ((var (mangle (gensym 'var))))
|
||||||
|
(cons
|
||||||
|
(string-append
|
||||||
|
"alloc_bignum(data," var ");"
|
||||||
|
var "->bn = " ,code ";")
|
||||||
|
(string-append var))))
|
||||||
((bool)
|
((bool)
|
||||||
(cons
|
(cons
|
||||||
""
|
""
|
||||||
|
@ -184,6 +193,8 @@
|
||||||
(cons
|
(cons
|
||||||
(string-append ,code ";")
|
(string-append ,code ";")
|
||||||
"Cyc_VOID"))
|
"Cyc_VOID"))
|
||||||
|
((data)
|
||||||
|
"data")
|
||||||
(else
|
(else
|
||||||
(error "c->scm unable to convert C object of type " ,type)))))))
|
(error "c->scm unable to convert C object of type " ,type)))))))
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue