mirror of
https://github.com/nim-lang/Nim.git
synced 2026-05-05 21:44:46 +00:00
IC: progress (#25339)
This commit is contained in:
@@ -85,9 +85,3 @@ func countSetBitsImpl*(x: SomeInteger): int {.inline.} =
|
||||
else:
|
||||
when sizeof(x) <= 4: result = countBitsImpl(x.uint32)
|
||||
else: result = countBitsImpl(x.uint64)
|
||||
|
||||
proc countBits32*(n: uint32): int {.compilerproc, inline.} =
|
||||
result = countSetBitsImpl(n)
|
||||
|
||||
proc countBits64*(n: uint64): int {.compilerproc, inline.} =
|
||||
result = countSetBitsImpl(n)
|
||||
|
||||
@@ -10,6 +10,13 @@
|
||||
# set handling
|
||||
|
||||
|
||||
# IC: compilerprocs now must be defined in system.nim or threadpool.nim!
|
||||
proc countBits32*(n: uint32): int {.compilerproc, inline.} =
|
||||
result = countSetBitsImpl(n)
|
||||
|
||||
proc countBits64*(n: uint64): int {.compilerproc, inline.} =
|
||||
result = countSetBitsImpl(n)
|
||||
|
||||
proc cardSetImpl(s: ptr UncheckedArray[uint8], len: int): int {.inline.} =
|
||||
var i = 0
|
||||
result = 0
|
||||
|
||||
Reference in New Issue
Block a user