Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

This is awesome! I wonder what the benefits and challenges of doing this at the AST level vs in LLVM IR are.

How much of the language needs to be supported by the AST bytecode interpreter to support precomputing constexprs?

If information about constexprs could be propagated to LLVM IR, could and LLVM IR interpreter be used to precompute constexprs?

Also, would a complete AST bytecode interpreter be useful for checks in clang static analyzer?



Ideally whole of it.

WG21 could have taken the approach to make everything available on C++11, instead they have been adding pieces bit by bit in each revision.

The ultimate goal is to have as much coverage as possible, even more so given that reflection depends on constexpr.

Ultimately like in many compiled managed languages, C++ toolchains will have a compiler and an interpreter available.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: