I suggest we ...

Record copy update should be able change the generic type

type A<'a> =
{
mutable x: 'a
}

let a = {x = 1}
{a with x="Hello"} // Type error

Since the x field is generic and F# is type safe, it would not be bad if the above was valid.

1 vote
Vote
Sign in
(thinking…)
Sign in with: facebook google
Signed in as (Sign out)
You have left! (?) (thinking…)
Marko Grdinic shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

0 comments

Sign in
(thinking…)
Sign in with: facebook google
Signed in as (Sign out)
Submitting...

F# Language

Feedback and Knowledge Base