(cherry picked from commit 95cc1abdc7)
This commit is contained in:
Neelesh Chandola
2018-10-28 18:57:17 +05:30
committed by narimiran
parent c8786ad197
commit c756983795

View File

@@ -901,7 +901,7 @@ proc toHex*(x: BiggestInt, len: Positive): string {.noSideEffect,
proc toHex*[T: SomeInteger](x: T): string =
## Shortcut for ``toHex(x, T.sizeOf * 2)``
runnableExamples:
doAssert toHex(1984) == "00000000000007C0"
doAssert toHex(1984'i64) == "00000000000007C0"
toHex(BiggestInt(x), T.sizeOf * 2)
proc toHex*(s: string): string {.noSideEffect, rtl.} =