#error: expected type *hash_map.HashMap, found *const hash_map.HashMap

1 messages · Page 1 of 1 (latest)

austere thicket
#

ctx is const but you modify it with ctx.connections.put

#

deinit should take self: *@This() as a parameter

#

Both

#

hashmap's deinit replaces its own memory with undefined to help you catch bugs in debug mode, so it requires a mutable pointer

#

and when you need a field to be mutable, you need to mark the struct as mutable