Next: , Previous: Wrapping a C Function, Up: G-Wrap's High-level API

Wrapping a C Constant

— method: wrap-constant! (wrapset <gw-wrapset>) . args

Add the C constant (either a macro or an enumerate value) defined by args to the list of constants to be wrapped by wrapset. The arguments in args must contain the following named parameters:

a symbol that is name given to the C constant in the target language binding;
a symbol denoting the type of this constant, more precisely the name of the wrapped-type for the constant's type;
a string representing the constant in C (e.g. "ENOMEM");
a string describing this constant.