My superficial understanding of variables in f # suggests that declaring a variable is "mutable" and using the variable "ref" essentially does the same. Both of them are different ways to solve the same main problem - a limited and structured accounting for variability in a functional language without the need to resort to IO Monad. In my understanding, the “technical” was “abstracted”.
- If so, why can't you capture exciting variables, but can they capture ref instances?
- More generally, what is the technical difference between the two forms that allow this difference?
- What is the goal in terms of language design with the representation of two abbreviations with a change, and not just one?
I apologize if this is a multi-starter, but they all seem interconnected.
closures f # mutability
Richard Warburton
source share