std.StringHashMap and std.AutoHashMap use managed (pre-0.16) APIFiles: N/A Severity: HIGH (downgraded) Status: ❌ FALSE POSITIVE
Verification: A standalone test confirming all managed HashMap APIs work without deprecation warnings:
test "StringHashMap still works" {
var map = std.StringHashMap(i32).init(testing.allocator);
defer map.deinit();
try map.put("hello", 42);
}
test "AutoHashMap still works" {
var map = std.AutoHashMap(i32, []const u8).init(testing.allocator);
defer map.deinit();
try map.put(1, "one");
}
Result: all pass, zero deprecation warnings.
Evidence from std lib source (hash_map.zig):
pub fn StringHashMap(comptime V: type) type — line 64, no @deprecatepub fn AutoHashMap(comptime K, comptime V) type — line 46, no @deprecatepub fn init(allocator: Allocator) Self — line 170, no @deprecatepub fn deinit(self: *Self) void — line 211, no @deprecateThe only deprecation notice in hash_map.zig is a doc comment on HashMapUnmanaged: “Default initialization of this struct is deprecated; use .empty instead.” This is about = .{} vs = .empty, not about the managed types.
No code changes needed.