dghosef / qdbp

MIT License
51 stars 1 forks source link

Import compilation #35

Closed dghosef closed 1 year ago

dghosef commented 1 year 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 1 year ago

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

dghosef commented 1 year 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