mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-09-24 22:02:23 +01:00
In `BuildUnaryOperator`, `GetOperatorOpFunction` is treated as desugaring, but `PerformCompoundMemberAccess` and `PerformCall` are not. This treats all of destruction as desugaring. This leads to some instructions being elided, because of `GetOrAddInst` behaviors: > // If the instruction has a desugared location and a constant value, returns > // the constant value's instruction ID. Otherwise, same as AddInst. This changes instructions that previously had a non-desugared location to instead have a desugared location, so if they also have a constant value then the constant value can be used directly.