10 ms·
In the presence of -Werror, this seems isomorphic to the notion of adding a '-fdynamic-type-errors' flag. It can't be done in full generality because, as I men
by dllthomas 10y ago
In the presence of -Werror, this seems isomorphic to the notion of adding a '-fdynamic-type-errors' flag.
It can't be done in full generality because, as I mentioned, there are places where term-level values depend on types. If we don't know what type, we can't know what term.
We could certainly treat only those situations where behavior is ambiguous like '-fdefer-type-errors' currently treats any type mismatch, and add dynamic checks for the rest. It would be an interesting point in the space, though not one I would expect to use very often.