Expand description
Raw bindings to libruby, generated by bindgen.
This module contains the raw bindings to libruby, generated by bindgen.
Structs
- @file
- @endcond
- @endcond
Enums
- @}
- @endcond
- @endcond
- @endcond
- special constants - i.e. non-zero and non-fixnum constants
- C-level type of an object.
Constants
Statics
Functions
- @endcond
- Inform the garbage collector that
valptrpoints to a live Ruby object that should not be moved. Note that extensions should use this API on global constants instead of assuming constants defined in Ruby are always alive. Ruby code can remove global constants. - Inform the garbage collector that
objectis a live Ruby object that should not be moved.
- Inform the garbage collector that a pointer previously passed to
[rb_gc_register_address]no longer points to a live Ruby object.
- @endcond
- An alias for
[rb_gc_register_address].
- @endcond
- @endcond
- rb_p⚠
- *_str_new_static functions are intended for C string literals. They require memory in the range [ptr, ptr+len] to always be readable. Note that this range covers a total of len + 1 bytes.
- @endcond
- @endcond
- @}
- @defgroup ruby1 ruby(1) implementation A part of the implementation of ruby(1) command. Other programs that embed Ruby interpreter do not always need to use these functions. @{
- ruby_vm_at_exit registers a function func to be invoked when a VM passed away. Functions registered this way runs in reverse order of registration, just like END {} block does. The difference is its timing to be triggered. ruby_vm_at_exit functions runs when a VM passed away, while END {} blocks runs just before a VM is passing away.
- Identical to ruby_xmalloc2(), except it zero-fills the region before it returns. This could also be seen as a routine identical to ruby_xmalloc(), except it calls calloc() instead of malloc() internally.
- Deallocates a storage instance.
- Allocates a storage instance. It is largely the same as system malloc(), except:
- Identical to ruby_xmalloc(), except it allocates
nelems*elemsizbytes. This is needed because the multiplication could integer overflow. On such situations Ruby does not try to allocate at all but raises Ruby level exceptions instead. If there is no integer overflow the behaviour is exactly the same asruby_xmalloc(nelems*elemsiz). - Resize the storage instance.
- Identical to ruby_xrealloc(), except it resizes the given storage instance to
newelems*newsizbytes. This is needed because the multiplication could integer overflow. On such situations Ruby does not try to touch the contents of argument pointer at all but raises Ruby level exceptions instead. If there is no integer overflow the behaviour is exactly the same asruby_xrealloc(ptr,nelems*elemsiz).