-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Closed
Labels
Description
Similar to the {.emit.} pragma for backend code, a hypothetical {.emith.} pragma would add the emitted code to the C generated header file, which would then be public to all other C generated files and other code. One possible use would be to generate specific constants in the form of enums or #defines since they are not supported by the language now (see #826).
The pragma could accept a position parameter to specify if the generated code has to be put before or after other generated code sections. This would also be a good time to define/document the order of the sections in the header, and also annotate them with C comments to indicate that the following exported functions come from which nimrod module.