On 2/24/21 2:38 PM, Mark wrote:
Is there a way to obtain a list, at compile-time, of all the exception types that a function might throw (directly or through a call to another function)?

Thanks.

Crazy idea:

Could a program import its own source file as a string (`string source = import('thisfile.d')`) and `-J<path>` , then use a lexer/parser to generate AST of the source code and extract exceptions potentially thrown by given functions -- all at compile time?

Reply via email to