Trying to generate a large interface withdt-ffi/define-library-interface throws an Exception. I'm not sure what the approximate limit is.
The structs and interface can be found at https://gist.github.com/phronmophobic/ee367a0e846868b13be41e7e5af82d49.
Workaround:
Spitting up the interface into multiple calls and multiple classes seems to work:
(def dtype-interface (gen/api->library-interface api))
(defmacro chunk-define []
`(do
~@(into
[]
(comp (map-indexed
(fn [i chunk]
(let [interface (into {} chunk)
classname (symbol (str (ns-name *ns* ) (str ".Bindings" i)))]
`(dt-ffi/define-library-interface (quote ~interface)
:classname (quote ~classname))))))
(partition-all 5 dtype-interface))))
(chunk-define)
Macros and data FTW!
Trying to generate a large interface with
dt-ffi/define-library-interfacethrows an Exception. I'm not sure what the approximate limit is.The structs and interface can be found at https://gist.github.com/phronmophobic/ee367a0e846868b13be41e7e5af82d49.
Workaround:
Spitting up the interface into multiple calls and multiple classes seems to work:
Macros and data FTW!