From 230a30ec9c7f0cbb68de0e2a8fb49cbe9fdff00b Mon Sep 17 00:00:00 2001 From: Andrei Alexandrescu Date: Wed, 28 Feb 2018 12:05:15 +0200 Subject: [PATCH] Minor improvements --- std/uni.d | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/std/uni.d b/std/uni.d index 8d9e1291b..e7c75fa36 100644 --- a/std/uni.d +++ b/std/uni.d @@ -7790,7 +7790,7 @@ if (isInputRange!S1 && isSomeChar!(ElementEncodingType!S1) int diff = lhs - rhs; if (!diff) continue; - else if ((lhs | rhs) < 0x80) + if ((lhs | rhs) < 0x80) { auto lowL = std.ascii.toLower(lhs); auto lowR = std.ascii.toLower(rhs); @@ -7822,7 +7822,7 @@ if (isInputRange!S1 && isSomeChar!(ElementEncodingType!S1) // one of chars is not cased at all return diff; } - return r2.empty ? 0 : -1; + return -int(r2.empty); } ///