mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-09-24 22:02:23 +01:00
As a byproduct, the only test that exercised the "address of a temporary object" diagnostic now trigers the "address of a non-reference expression" diagnostic. We could restore it by using a type that doesn't support `value_of_initializer`, but it seems better to remove the diagnostic altogether: not only does it simplify the code, I'd also argue "non-reference expression" is more accurate as a user-facing description of the operand.