Do you have a concrete example of what you’re trying to do? It doesn’t make sense to merge two records like that.
Consider this example:
type t = {x: int, y: string}
let a = {x: 1, y: "a"}
let b = {x: 2, y: "b"}
let c = {...a, ...b} // What should we expect c to be?
If we do the same idea manually:
let c = {...a, x: b.x, y: b.y}
Then we end up with a record that’s just identical to b, which defeats the idea of a “merge.” In fact, the compiler will even warn you about doing this:
All the fields are already explicitly listed in this record.
You can remove the `...` spread.