The OCaml module was generating dead code in the wrappers for overloaded functions. Only the generated dispatch function needs to allocate an array for the passed arguments. In addition, add overload_extend, overload_rename and overload_subtype runtime tests.
7 lines
235 B
OCaml
7 lines
235 B
OCaml
open Swig
|
|
open Overload_rename
|
|
|
|
let _ = new_Foo (C_float 1.)
|
|
let _ = new_Foo (C_list [ C_float 1. ; C_float 1. ])
|
|
let _ = new_Foo_int (C_list [ C_float 1. ; C_int 1 ])
|
|
let _ = new_Foo_int (C_list [ C_float 1. ; C_int 1 ; C_float 1. ])
|