Report diagnostics for type conversions

When modeling primitive widening conversions, report diagnostics for
invalid conversions instead of crashing.

This rearranges the implementation to use switches on the primitive
type kinds and casts instead of double-dispatch. The new approach makes
it easier to access the position information needed to report a
diagnostic, and also makes it more explicit which constants implement
a particular conversion.

PiperOrigin-RevId: 385854947
10 files changed
tree: 2132e2277d197372d57378c61b9553a93b57633e
  1. .github/
  2. java/
  3. javatests/
  4. proto/
  5. .gitattributes
  6. .gitignore
  7. LICENSE
  8. pom.xml
  9. README.md
README.md

Turbine

Turbine is a header compiler for Java.