diff --git a/Examples/ocaml/simple/example_prog.ml b/Examples/ocaml/simple/example_prog.ml index 5dafdc219..b8bc619e7 100644 --- a/Examples/ocaml/simple/example_prog.ml +++ b/Examples/ocaml/simple/example_prog.ml @@ -1,5 +1,6 @@ (* example_prog.ml *) +open Swig open Example (* Call our gcd() function *) diff --git a/Examples/ocaml/std_string/runme.ml b/Examples/ocaml/std_string/runme.ml index d6a933a1c..f178b9bc2 100644 --- a/Examples/ocaml/std_string/runme.ml +++ b/Examples/ocaml/std_string/runme.ml @@ -1,5 +1,6 @@ (* This example was mostly lifted from the guile example directory *) +open Swig open Example let y = "\205\177" diff --git a/Examples/ocaml/std_vector/example.i b/Examples/ocaml/std_vector/example.i index 385353ade..60285e529 100644 --- a/Examples/ocaml/std_vector/example.i +++ b/Examples/ocaml/std_vector/example.i @@ -8,10 +8,8 @@ %include stl.i /* instantiate the required template specializations */ -namespace std { - %template(IntVector) std::vector; - %template(DoubleVector) std::vector; -} +%template(IntVector) std::vector; +%template(DoubleVector) std::vector; /* Let's just grab the original header file here */ %include "example.h" diff --git a/Examples/ocaml/std_vector/runme.ml b/Examples/ocaml/std_vector/runme.ml index c6c8846f1..6bc206237 100644 --- a/Examples/ocaml/std_vector/runme.ml +++ b/Examples/ocaml/std_vector/runme.ml @@ -1,5 +1,6 @@ (* This example was mostly lifted from the guile example directory *) +open Swig open Example (* repeatedly invoke a procedure with v and an index as arguments *) diff --git a/Examples/ocaml/stl/runme.ml b/Examples/ocaml/stl/runme.ml index 82ac7a044..54146ebe0 100644 --- a/Examples/ocaml/stl/runme.ml +++ b/Examples/ocaml/stl/runme.ml @@ -1,5 +1,6 @@ (* This example was mostly lifted from the guile example directory *) +open Swig open Example let v = new_StringVector C_void