When a C variable or macro is imported via an {.importc.} var or
let statement, but no definition is needed and the variable does
not have an initializer part, then there is also no need to generate
an #include for the associated header until and unless the variable
is actually used. The header is already generated upon use, but
unnecessarily also when the variable is defined.
This is an issue with the posix module in particular, where a lot
of unnecessary header files are being included because relevant
constants are defined via importc vars, and those header files
may not even be available on a given system.
This patch omits the generation of the #include directive for those
definitions where they aren't needed.
This directory contains the Nimrod compiler written in Nimrod. Note that this
code has been translated from a bootstrapping version written in Pascal, so
the code is **not** a poster child of good Nimrod code.