MCPcopy Create free account
hub / github.com/Effect-TS/effect / beginMutation

Function beginMutation

packages/effect/src/internal/hashMap.ts:1066–1071  ·  view source on GitHub ↗
(self: HashMap<K, V>)

Source from the content-addressed store, hash-verified

1064
1065/** @internal */
1066export const beginMutation = <K, V>(self: HashMap<K, V>): HashMap<K, V> => {
1067 const impl = self as HashMapImpl<K, V>
1068 // An open source must stop editing the nodes it now shares with the new batch.
1069 const edit = impl._editable ? ++impl._edit : impl._edit + 1
1070 return new HashMapImpl(true, edit, impl._root, impl._size)
1071}
1072
1073/** @internal */
1074export const endMutation = <K, V>(self: HashMap<K, V>): HashMap<K, V> => {

Callers 1

hashMap.tsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected