diff options
author | LemonBoy <LemonBoy@users.noreply.github.com> | 2018-09-05 20:57:50 +0200 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2018-09-05 20:57:50 +0200 |
commit | 36e6ca16d1ece106d88fbb951b544b80c360d600 (patch) | |
tree | a99c1b67cad393c1189c5082182998693defefc1 /lib | |
parent | d34233b5014ee1fbe7a1d5c176eb6cc221208717 (diff) | |
download | Nim-36e6ca16d1ece106d88fbb951b544b80c360d600.tar.gz |
Fix too broad generic match for toHex (#8889)
Fixes #8865
Diffstat (limited to 'lib')
-rw-r--r-- | lib/pure/strutils.nim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/pure/strutils.nim b/lib/pure/strutils.nim index 7730aa7a2..396f14972 100644 --- a/lib/pure/strutils.nim +++ b/lib/pure/strutils.nim @@ -820,7 +820,7 @@ proc toHex*(x: BiggestInt, len: Positive): string {.noSideEffect, # handle negative overflow if n == 0 and x < 0: n = -1 -proc toHex*[T](x: T): string = +proc toHex*[T: SomeInteger](x: T): string = ## Shortcut for ``toHex(x, T.sizeOf * 2)`` toHex(BiggestInt(x), T.sizeOf * 2) |