mirror of
https://github.com/nim-lang/Nim.git
synced 2026-01-06 04:57:49 +00:00
committed by
Andreas Rumpf
parent
dfb8730f51
commit
95cc1abdc7
@@ -909,7 +909,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.} =
|
||||
|
||||
Reference in New Issue
Block a user