ponyc icon indicating copy to clipboard operation
ponyc copied to clipboard

RFC: Export functions for calling class methods from C

Open SeanTAllen opened this issue 9 years ago • 4 comments

This RFC proposes the addition of an export keyword to specify that functions for a class should be generated even if they are not used directly in the Pony program that is being compiled. Additionally, wrapper functions for these functions that conform to the C ABI will be generated, along with a .h file with the appropriate function signatures so that the functions can be easily used from a C program. The .h file will only be generated if the program is compiled with the --export compiler flag.

Note that in addition to code, this RFC has test and documentation requirements that have to be done in order to merge. Full RFC details are at:

https://github.com/ponylang/rfcs/blob/master/text/0018-export.md

SeanTAllen avatar Oct 20 '16 02:10 SeanTAllen