Nim/compiler
Reimer Behrends 80356f1cc7 Avoid unnecessary #include triggered by importc vars.
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.
2014-09-19 03:34:00 +02:00
..
aliases.nim 'nil' as a statement is deprecated, use an empty 'discard' instead 2014-01-19 16:54:59 +01:00
ast.nim Adds documentation on skipTypes and mapType 2014-08-09 16:40:58 -04:00
astalgo.nim fixes #1334 2014-08-19 22:35:16 +02:00
babelcmd.nim case consistency: cs:partial bootstraps on windows 2013-12-29 03:19:10 +01:00
bitsets.nim case consistency part 1 2013-12-27 15:48:53 +01:00
canonicalizer.nim implements strongSpaces parsing mode 2014-03-07 22:25:05 +01:00
ccgcalls.nim fixes #1434 2014-08-14 00:02:24 +02:00
ccgexprs.nim fixes #1434 2014-08-14 00:02:24 +02:00
ccgmerge.nim removed dead code 2014-03-04 08:30:11 +01:00
ccgstmts.nim Avoid unnecessary #include triggered by importc vars. 2014-09-19 03:34:00 +02:00
ccgthreadvars.nim case consistency: cs:partial bootstraps on windows 2013-12-29 03:19:10 +01:00
ccgtrav.nim fixes #1434 2014-08-14 00:02:24 +02:00
ccgtypes.nim fixes #1143 2014-08-19 10:01:46 +02:00
ccgutils.nim fixes #1143 2014-08-19 10:01:46 +02:00
cgen.nim Merge pull request #1481 from rbehrends/fix-stackscan2 2014-08-14 09:16:26 +02:00
cgendata.nim optimized method dispatchers 2014-06-12 16:05:50 +02:00
cgmeth.nim implemented region pointers 2014-04-09 00:33:51 +02:00
commands.nim distinguish between 'defined' and 'declared' 2014-08-11 20:38:28 +02:00
condsyms.nim fixes #1492 2014-08-17 21:23:46 +02:00
crc.nim case consistency: next steps 2013-12-29 01:13:51 +01:00
depends.nim 'nil' as a statement is deprecated, use an empty 'discard' instead 2014-01-19 16:54:59 +01:00
docgen.nim Moves TOC index entry generation to rstgen module. 2014-04-21 21:05:38 +02:00
docgen2.nim 'nil' as a statement is deprecated, use an empty 'discard' instead 2014-01-19 16:54:59 +01:00
evalffi.nim implemented region pointers 2014-04-09 00:33:51 +02:00
evaltempl.nim case consistency: next steps 2013-12-29 01:13:51 +01:00
extccomp.nim Fix compilation error when using packed pragma with vcc. 2014-03-18 21:23:35 +01:00
filter_tmpl.nim 'nil' as a statement is deprecated, use an empty 'discard' instead 2014-01-19 16:54:59 +01:00
filters.nim case consistency: next steps 2013-12-29 01:13:51 +01:00
guards.nim fixes tinavlid_array_bounds test 2014-08-10 13:46:42 +02:00
hlo.nim fixes #798 2014-04-06 22:05:42 +02:00
idents.nim case consistency part 1 2013-12-27 15:48:53 +01:00
idgen.nim fixed tuples in a static context; preparations for correct compile time evaluation of integral ops 2014-03-22 02:52:06 +01:00
importer.nim Renamed considerAccents to considerQuotedIdent 2014-05-26 10:42:10 -04:00
jsgen.nim documented the JS codegen 2014-08-20 01:11:47 +02:00
jstypes.nim implemented region pointers 2014-04-09 00:33:51 +02:00
lambdalifting.nim fixes #665 2014-09-11 19:54:49 +02:00
lexer.nim 'lambda' is no keyword anymore 2014-08-08 02:24:19 +02:00
lists.nim Fix #813 2014-07-29 21:13:21 -04:00
llstream.nim distinguish between 'defined' and 'declared' 2014-08-11 20:38:28 +02:00
lookups.nim Renamed considerAccents to considerQuotedIdent 2014-05-26 10:42:10 -04:00
lowerings.nim fixes #665 2014-09-11 19:54:49 +02:00
magicsys.nim some progress for jester+async 2014-06-27 16:03:11 +02:00
main.nim gpp -> gcc 2014-05-09 23:22:43 +02:00
modules.nim Fix generation of package-dependent init names. 2014-06-25 00:42:55 +02:00
msgs.nim compiler prepared for the new comment handling 2014-04-30 00:53:44 +02:00
nimconf.nim 'nil' as a statement is deprecated, use an empty 'discard' instead 2014-01-19 16:54:59 +01:00
nimeval.nim xmltree.<> macro works again 2014-02-27 20:47:44 +01:00
nimlexbase.nim case consistency: cs:partial bootstraps on windows 2013-12-29 03:19:10 +01:00
nimrod.ini Add 'lib/pure/concurrency' path to nimrod.ini 2014-06-27 18:20:42 -04:00
nimrod.nim distinguish between 'defined' and 'declared' 2014-08-11 20:38:28 +02:00
nimrod.nimrod.cfg fixes #913 2014-04-06 17:26:20 +02:00
nimsets.nim case consistency: cs:partial bootstraps on windows 2013-12-29 03:19:10 +01:00
nversion.nim devel is version 0.9.5 2014-04-22 21:38:44 +02:00
options.nim fixes 'gcsafe' 2014-08-12 08:47:31 +02:00
parampatterns.nim implemented builtin noncopying slice 2014-05-02 08:44:03 +02:00
parser.nim fixes #1161 2014-07-01 21:47:53 +02:00
passaux.nim 'nil' as a statement is deprecated, use an empty 'discard' instead 2014-01-19 16:54:59 +01:00
passes.nim removed flawed thread analysis pass 2014-04-20 14:00:04 +02:00
patterns.nim fixes #1285 2014-06-30 23:36:46 +02:00
pbraces.nim case consistency part 1 2013-12-27 15:48:53 +01:00
platform.nim case consistency part 4 2013-12-27 23:10:36 +01:00
pragmas.nim progress on deepCopy 2014-08-01 23:40:48 +02:00
pretty.nim fixes #1285 2014-06-30 23:36:46 +02:00
procfind.nim 'nil' as a statement is deprecated, use an empty 'discard' instead 2014-01-19 16:54:59 +01:00
readme.txt Removes executable bit for text files. 2013-03-16 23:53:07 +01:00
renderer.nim 'lambda' is no keyword anymore 2014-08-08 02:24:19 +02:00
rodread.nim new VM is getting stable 2014-02-24 01:30:40 +01:00
rodutils.nim Fix more 'undeclared identifier' errors. 2014-05-14 18:12:47 +02:00
rodwrite.nim 'nil' as a statement is deprecated, use an empty 'discard' instead 2014-01-19 16:54:59 +01:00
ropes.nim master compiler compiles with devel 2014-01-23 16:45:17 +01:00
saturate.nim case consistency part 4 2013-12-27 23:10:36 +01:00
sem.nim progress on 'spawn' 2014-08-10 03:17:30 +02:00
semcall.nim Fixes #710. 2014-08-16 00:46:14 +01:00
semdata.nim Merge pull request #1281 from Araq/new_spawn 2014-06-16 23:03:17 +02:00
semdestruct.nim progress on deepCopy 2014-08-01 23:40:48 +02:00
semexprs.nim minor bugfix for void .compileTime procs 2014-09-11 00:36:31 +02:00
semfold.nim fixes constant array indexing bug 2014-06-30 16:45:55 +02:00
semgnrc.nim fixes #1444 2014-09-11 00:34:59 +02:00
seminst.nim fixes #669 2014-08-14 21:56:06 +02:00
semmacrosanity.nim better tester 2014-01-17 08:47:51 +01:00
semmagic.nim fixes #1366 2014-09-11 09:53:00 +02:00
semparallel.nim progress on 'spawn' 2014-08-10 03:17:30 +02:00
sempass2.nim fixes 'gcsafe' 2014-08-12 08:47:31 +02:00
semstmts.nim fixes #1511 2014-09-11 00:45:29 +02:00
semtempl.nim fixes #1285 2014-06-30 23:36:46 +02:00
semtypes.nim implements #1332 2014-07-06 22:56:34 +02:00
semtypinst.nim mostly fixes #1339 2014-09-11 09:57:33 +02:00
service.nim normalize "run" command 2014-07-29 02:16:57 +02:00
sigmatch.nim fixes #1285 2014-06-30 23:36:46 +02:00
suggest.nim fixes #1285 2014-06-30 23:36:46 +02:00
syntaxes.nim Delete dead file 2014-04-19 17:19:22 -04:00
tccgen.nim Allow arguments for "nimrod run" 2014-07-28 17:41:00 +02:00
testability.nim distinguish between 'defined' and 'declared' 2014-08-11 20:38:28 +02:00
transf.nim fixes recently introduced regression 2014-08-21 09:59:57 +02:00
trees.nim case consistency: cs:partial bootstraps on windows 2013-12-29 03:19:10 +01:00
treetab.nim case consistency: next steps 2013-12-29 01:13:51 +01:00
types.nim mostly fixes #1339 2014-09-11 09:57:33 +02:00
typesrenderer.nim Renamed 'considerAcc' to 'considerAccents' for clarity 2014-05-24 08:10:40 -04:00
vm.nim Fixes incorrect macro stack traces. 2014-08-11 20:47:38 +01:00
vmdef.nim Fixes incorrect macro stack traces. 2014-08-11 20:47:38 +01:00
vmdeps.nim Properly handle staticExec() generating large output. 2014-09-10 01:22:20 +02:00
vmgen.nim fixes #903, fixess #1513 2014-09-11 01:45:14 +02:00
wordrecg.nim 'lambda' is no keyword anymore 2014-08-08 02:24:19 +02:00

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.