qdbplang / qdbp

MIT License
50 stars 1 forks source link

Import compilation #35

Closed dghosef closed 10 months ago

dghosef commented 10 months ago

Currently, when generating C code for imports, we just paste the C code for that import. However, if the same file is imported multiple times, this generates way too much code. We should try not to duplicate. However, semantically we should have the same behavior as if it were pasted.

dghosef commented 10 months ago

Alternatively, we can have the autoformatter just move the import up to the top and save it in a variable

dghosef commented 10 months ago

I honestly think that the current import strategy is ok(just pasting the ast) and we should fix it only when we run into problems