Restructure branching slighty. Fix error message.

This commit is contained in:
Oscar Campbell 2015-06-01 23:49:04 +02:00
commit dd30bab480
2 changed files with 9 additions and 9 deletions

View file

@ -130,14 +130,13 @@ proc hashIgnoreStyle*(x: string): THash =
var c = x[i]
if c == '_':
inc(i)
continue # skip _
if isMagicIdentSeparatorRune(cstring(x), i):
elif isMagicIdentSeparatorRune(cstring(x), i):
inc(i, magicIdentSeparatorRuneByteWidth)
continue # skip '·' (unicode middle dot)
if c in {'A'..'Z'}:
c = chr(ord(c) + (ord('a') - ord('A'))) # toLower()
h = h !& ord(c)
inc(i)
else:
if c in {'A'..'Z'}:
c = chr(ord(c) + (ord('a') - ord('A'))) # toLower()
h = h !& ord(c)
inc(i)
result = !$h