β‰ˆ the.bay.news

Memory leak with BufMap

Ziggit
Memory leak with BufMap
Hi πŸ™‚ My understanding of the documentation of BufMap is that the deinit should take care of freeing all the entries (keys and values) along with the backing storage (it’s also my understanding of its implementation). Now the following test reports a memory leak: test "simple test" { const gpa = std.testing.allocator; var map = std.BufMap.init(gpa); errdefer map.deinit(); try map.put("alice", "bob"); } What did I miss? I’m on version 0.17.0.

0 comments

Sign in to join the discussion β€” your thebay.events account works here.

No comments yet.