This function should yield an error when called.
immediate bool check() {
int x = 3;
class_info ci = reflexpr(x); // ci is empty
// const char* str = ci.name();
compiler.print(ci.name());
However, the call to print() seems to eat any diagnostics resulting from invalid use of an empty reflection. Uncommenting the line above yields the correct error.
This may be related to the fact that print() is a void function.
This function should yield an error when called.
However, the call to
print()seems to eat any diagnostics resulting from invalid use of an empty reflection. Uncommenting the line above yields the correct error.This may be related to the fact that
print()is avoidfunction.