Commits

Anonymous committed bc34897

fix doc: call lib.Close()

Comments (0)

Files changed (1)

   // dl-open a library: here, libm on macosx
   lib, err := ffi.NewLibrary("libm.dylib")
   handle_err(err)
-  
+
   // get a handle to 'cos', with the correct signature
   cos, err := lib.Fct("cos", ffi.Double, []Type{ffi.Double})
   handle_err(err)
   out := cos(0.).Float()
   println("cos(0.)=", out)
 
+  err = lib.Close()
+  handle_err(err)
 
 Limitations/TODO
 -----------------