swig/Examples/ocaml/contract/example_prog.ml
Art Yerkes 2e96036cdb Added contract example.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@5375 626c5289-ae23-0410-ae9c-e8d60b6d4f22
2003-11-23 12:55:53 +00:00

7 lines
235 B
OCaml

open Swig
open Example
let _ = print_endline "This won't throw."
let _ = Printf.printf "Cos 1.0 is %f\n" (_cos '(1.0) as float)
let _ = print_endline "This will throw."
let _ = Printf.printf "Cos 5.0 is %f\n" (_cos '(5.0) as float)