method

new

new(addr, types, func = nil)
public

Wraps the C pointer addr as a C struct with the given types. The C function func is called when the instance is garbage collected.

See also DL::CPtr.new