-
Notifications
You must be signed in to change notification settings - Fork 847
Closed
Labels
Milestone
Description
open System
let x() =
let y () = 3
let (a,b) =
if DateTime.Now.Day > 1 then
y(), 2
else
2, y()
a + bI would expect a direct tuple/detuple in a binding, like the above, to be rewritten to mutable a and b mutated directly from their branches.
In cases where detupling is successful (example of a case below) the entire function compiles down to the result of a + b.
let x() =
let y () = 3
let (a,b) =
y(), 2
a + bRelated:
dotnet/coreclr#21950