[OCaml] Fix a bug in the ctors of director classes

If a class was given the director feature, it was not possible
to use ctors with multiple parameters.

Add director_default_runme.ml (it is based on
director_default_runme.java).
This commit is contained in:
Zackery Spytz 2019-02-05 13:35:43 -07:00
commit 828ce477c8
5 changed files with 45 additions and 6 deletions

View file

@ -70,6 +70,11 @@ class wstring;
swig_result = caml_list_append(swig_result,caml_val_string_len((*$1).c_str(), (*$1).size()));
}
%typemap(directorin) string {
swig_result = caml_val_string_len($1.c_str(), $1.size());
args = caml_list_append(args, swig_result);
}
%typemap(directorout) string {
$result.assign((char *)caml_ptr_val($input,0), caml_string_len($input));
}