6 ms·
Immutable structures cannot be cyclical. Maybe I’m missing something?
by pharmakom 3y ago
Immutable structures cannot be cyclical. Maybe I’m missing something?
- nlitened 3y agoIn Clojure, the data structures may usually contain references to mutable cells, which in turn may form cycles.
- Jeaye 3y agoExactly as nlitened mentioned, Clojure has a few difference reference types, which are boxes that hold pointers to more immutable values. The values within those boxes can be changed transactionally. This allows for cyclical references.