Join Slack
Powered by
Is there anything i can use that is like apply but...
# stdlib
a
asad.awadia
12/05/2019, 8:39 PM
Is there anything i can use that is like apply but doesn’t mutate the original object and instead returns a copy?
m
Mike
12/05/2019, 9:05 PM
Only if it's a data class. Then you have the copy function and can used named parameters syntax to replace values in the copy.
4
Views
Open in Slack
Previous
Next