varargs-callback-quot ( return types abi named-count -- quot )


Vocabulary
alien.parser

Inputs
returnan object
typesan object
abian object
named-countan object


Outputs
quotan object


Definition


:: varargs-callback-quot
( return types abi named-count -- quot )
types named-count head :> named types named-count tail
:> tail tail empty?
[ '[ [ return named abi ] dip alien-callback-varargs ] ] [
"alien.varargs" require
"va-arg" "alien.varargs" lookup-word :> read-arg tail
[| type | type read-arg '[ dup _ @ swap ] ] map concat
[ drop ] append :> reader '[
[ return named abi ] dip [ reader ] dip compose
alien-callback-varargs
]
] if ;