Howto:Extend Nasal: Difference between revisions

Jump to navigation Jump to search
m
Line 42: Line 42:
     { 0, 0 }
     { 0, 0 }
   };
   };
So, the basic format is "name", function_pointer - whereas function_pointer has to use the right function signature:
// The function signature for an extension function:
typedef naRef (*naCFunction)(naContext ctx, naRef me, int argc, naRef* args);


You will need to add your new extension function to this list of static functions, preferably following the existing naming convention (i.e. "f_" prefix).
You will need to add your new extension function to this list of static functions, preferably following the existing naming convention (i.e. "f_" prefix).
2,561

edits

Navigation menu