3 ms·
Sure, but I wouldn't say that's easy.
by dthul 4y ago
Sure, but I wouldn't say that's easy.
- germandiago 4y agoI have found table-generation and processing at compile-time to be of big help. For example, pre-computing values or parsing at compile-time. This is useful for example in the following situations: - You want to embed things at compile-time but keep things apart in a file. This file can be used at run-time when developing but is embedded and literally vanishes (you put your config directly in a struct) when deploying. - You do not want to spend extra time at compile-time. - No need to protect data at run-time with mutexes, etc. The simplification it can yield is not immediately obvious. It can take a bit more work but the result is worth it. D is more powerful than C++ at this, btw.