replace some runtime repr in stdlib for gc:arc (#12716)

This commit is contained in:
Andy Davidoff 2019-11-25 04:13:30 -05:00 • committed by Andreas Rumpf
commit bd8f49cbd3
3 changed files with 5 additions and 4 deletions

View file

@ -190,8 +190,8 @@ proc decode*(s: string): string =
inc inputIndex
if x == invalidChar:
raise newException(ValueError,
"Invalid base64 format character " & repr(s[inputIndex]) &
" at location " & $inputIndex & ".")
"Invalid base64 format character `" & s[inputIndex] &
"` (ord " & $s[inputIndex].ord & ") at location " & $inputIndex & ".")
template outputChar(x: untyped) =
result[outputIndex] = char(x and 255)