authorgravatar for johnnymarler@gmail.comJonathan Marler <johnnymarler@gmail.com> 2022-02-06 23:30:06-07:00
committergravatar for johnnymarler@gmail.comJonathan Marler <johnnymarler@gmail.com> 2022-05-11 18:41:23-06:00
log8492ced0755924b3c4c0d67fb306d65bffd0933a
treee39cb1fcc63af6978fd7818a91cde7ee0af219de
parent71f69190ef7a79650647cf5422633813756fbe48

incorporate review changes from squeek


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

lib/std/process.zig+7-1
......@@ -100,7 +100,7 @@ pub const EnvMap = struct {
100100 if (upcase(c_a) != upcase(c_b))
101101 return false;
102102 }
103 if (it_b.nextCodepoint()) |_| return false;
103 return if (it_b.nextCodepoint()) |_| false else true;
104104 }
105105 return std.hash_map.eqlString(a, b);
106106 }
......@@ -232,6 +232,12 @@ test "EnvMap" {
232232 try testing.expect(env.get("SOMETHING_NEW") == null);
233233
234234 try testing.expectEqual(@as(EnvMap.Size, 1), env.count());
235
236 // test Unicode case-insensitivity on Windows
237 if (builtin.os.tag == .windows) {
238 try env.put("КИРиллИЦА", "something else");
239 try testing.expectEqualStrings("something else", env.get("кириллица").?);
240 }
235241}
236242
237243/// Returns a snapshot of the environment variables of the current process.