Automatically clone references to value types
Then references to value types are passed to owned values, they're now cloned automatically. This makes it much easier to pass value types around, regardless of whether they're owned values or references.
This in turn means methods no longer have to decide if they want to take
e.g. a ref Int
or Int
, as they can just specify Int
as the type
and any ref Int
passed is automatically cloned into a new Int
.
This fixes #280 (closed)