Need diagnostic for mismatched Either branches in result builder #78655
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
triage needed
This issue needs more specific labels
Description
Not getting this right yields:
error: failed to produce diagnostic for expression; please submit a bug report (https://swift.org/contributing/#reporting-bugs)
Reproduction
Expected behavior
No request to file a bug; good diagnostic. An explanation of the rules in the docs.
Environment
swift-driver version: 1.115.1 Apple Swift version 6.0.3 (swiftlang-6.0.3.1.10 clang-1600.0.30.1)
Target: x86_64-apple-macosx15.0
Additional information
The exact rules are weird; there's probably a lot of type deduction going on.
For example, this works:
This of course fails (understandable):
One might expect this to work but it fails the same way:
The text was updated successfully, but these errors were encountered: