|
infix
A JIT-Powered FFI Library for C
|
Cookbook Chapter 6: Reading and Writing Global Variables. More...
Classes | |
| struct | Config |
Functions | |
| int | main () |
Variables | |
| const char * | LIB_NAME = "./libglobals.so" |
Cookbook Chapter 6: Reading and Writing Global Variables.
This example demonstrates how to use infix_read_global and infix_write_global to interact with global variables exported from a shared library. The infix signature language is used to describe the type of the variable, ensuring that the correct number of bytes are read or written, which prevents memory corruption.
| int main | ( | void | ) |
| const char* LIB_NAME = "./libglobals.so" |