Effect Ffipub

Source
:effect(pub) Ffi
  .load-library ( Str  (Result AnyUInt Str) )
  .lookup ( AnyUInt Str  (Result AnyUInt Str) )
  .call-void ( AnyUInt  (Result Unit Str) )
Description

FFI effect — load dynamic libraries and call native symbols. Library and Symbol handles are AnyUInt identifiers in this provisional decl; the typed (Symbol sig) form lands later.

Parent chain:IOFfi

Operations

.load-library ( Str (Result AnyUInt Str) )

Load a dynamic library from the given path, returning a handle.

.lookup ( AnyUInt Str (Result AnyUInt Str) )

Look up a symbol by name within a previously loaded Library.

.call-void ( AnyUInt (Result Unit Str) )

Call a symbol that takes no args and returns nothing. Richer signatures arrive with the typed-marshalling WP.