authorgravatar for AlliedEnvy@users.noreply.github.comAlliedEnvy <AlliedEnvy@users.noreply.github.com> 2023-12-22 19:08:03-06:00
committergravatar for git@vexu.euVeikka Tuominen <git@vexu.eu> 2023-12-23 16:15:19+02:00
log1b0e913e0fcc63b48778be300b0705ceb1fd84f1
treeeaa3d9fb9226e6929871e169996ad41260549a45
parent21ae64852a531c36ae3166aa2b6f1fbaaf76c6f9

std.hash_map: clarify error when Context is missing pub hash/eql


1 files changed, 2 insertions(+), 2 deletions(-)

lib/std/hash_map.zig+2-2
...@@ -251,7 +251,7 @@ pub fn verifyContext(...@@ -251,7 +251,7 @@ pub fn verifyContext(
251 errors = errors ++ lazy.err_invalid_hash_signature;251 errors = errors ++ lazy.err_invalid_hash_signature;
252 }252 }
253 } else {253 } else {
254 errors = errors ++ lazy.prefix ++ @typeName(Context) ++ " must declare a hash function with signature " ++ lazy.hash_signature;254 errors = errors ++ lazy.prefix ++ @typeName(Context) ++ " must declare a pub hash function with signature " ++ lazy.hash_signature;
255 }255 }
256256
257 // Verify Context.eql(self, PseudoKey, Key) => bool257 // Verify Context.eql(self, PseudoKey, Key) => bool
...@@ -335,7 +335,7 @@ pub fn verifyContext(...@@ -335,7 +335,7 @@ pub fn verifyContext(
335 errors = errors ++ lazy.err_invalid_eql_signature;335 errors = errors ++ lazy.err_invalid_eql_signature;
336 }336 }
337 } else {337 } else {
338 errors = errors ++ lazy.prefix ++ @typeName(Context) ++ " must declare a eql function with signature " ++ lazy.eql_signature;338 errors = errors ++ lazy.prefix ++ @typeName(Context) ++ " must declare a pub eql function with signature " ++ lazy.eql_signature;
339 }339 }
340340
341 if (errors.len != 0) {341 if (errors.len != 0) {