Make final vals have constant types if rhs is a constant.
Make final vals have constant types if rhs is a constant.

This duplicates scalac behavior. Awaiting inline, this is a stopgap because we need this to work
for the bootstrap. Once we have inline (and a migration tool that rewrites final to final inline)
we can migrate this functionality over to inline values.

auvik/dotty,svalaskevicius/dotty,reactormonk/dotty,som-snytt/dotty,densh/dotty,sjrd/dotty,sjrd/dotty,yusuke2255/dotty,auvik/dotty,VladimirNik/dotty,VladimirNik/dotty,som-snytt/dotty,svalaskevicius/dotty,sjrd/dotty,lampepfl/dotty,dotty-staging/dotty,lampepfl/dotty,dotty-staging/dotty,lampepfl/dotty,yusuke2255/dotty,som-snytt/dotty,sjrd/dotty,densh/dotty,dotty-staging/dotty,som-snytt/dotty,sjrd/dotty,reactormonk/dotty,dotty-staging/dotty,lampepfl/dotty,som-snytt/dotty,dotty-staging/dotty,lampepfl/dotty