mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-25 13:05:05 +02:00
Call proper conversion function
This commit is contained in:
parent
1bd664b813
commit
d62166d5d7
2 changed files with 4 additions and 4 deletions
|
@ -203,7 +203,7 @@
|
||||||
var
|
var
|
||||||
(cond
|
(cond
|
||||||
(arg-cust-type
|
(arg-cust-type
|
||||||
(if (= 3 (length arg-cust-type))
|
(if (> (length arg-cust-type) 1)
|
||||||
(set! arg-cust-convert #t))
|
(set! arg-cust-convert #t))
|
||||||
(car arg-cust-type))
|
(car arg-cust-type))
|
||||||
(else
|
(else
|
||||||
|
@ -249,8 +249,8 @@
|
||||||
(hash-table-ref *foreign-types* (quote ,type)))))
|
(hash-table-ref *foreign-types* (quote ,type)))))
|
||||||
(pass-arg
|
(pass-arg
|
||||||
(if (and arg-cust-type
|
(if (and arg-cust-type
|
||||||
(= 3 (length arg-cust-type)))
|
(> (length arg-cust-type) 1))
|
||||||
`(,(caddr arg-cust-type) ,sym)
|
`(,(cadr arg-cust-type) ,sym)
|
||||||
sym)) )
|
sym)) )
|
||||||
(cons
|
(cons
|
||||||
sym ;; Arg
|
sym ;; Arg
|
||||||
|
|
|
@ -44,7 +44,7 @@
|
||||||
;(c-define scm-strlen "int" "strlen" string)
|
;(c-define scm-strlen "int" "strlen" string)
|
||||||
(c-define scm-strlend double "strlen" string)
|
(c-define scm-strlend double "strlen" string)
|
||||||
(c-define scm-strlen2 integer "strlen" my-string)
|
(c-define scm-strlen2 integer "strlen" my-string)
|
||||||
(c-define scm-strlen3 integer "strlen" my-integer-as-string)
|
(c-define scm-strlen3 integer "strlen" string-as-integer)
|
||||||
|
|
||||||
(test-group "foreign lambda"
|
(test-group "foreign lambda"
|
||||||
(test 15 (scm-strlen "testing 1, 2, 3"))
|
(test 15 (scm-strlen "testing 1, 2, 3"))
|
||||||
|
|
Loading…
Add table
Reference in a new issue