mirror of
https://github.com/nim-lang/Nim.git
synced 2025-12-30 01:44:37 +00:00
* fix #20997 calling system.card[T](x: set[T]) with T of int8 or uint8 uses mismatched C array sizes * fullfil set variant
19 lines
209 B
Nim
19 lines
209 B
Nim
discard """
|
|
joinable: false
|
|
"""
|
|
|
|
{.passC: "-flto".}
|
|
{.passL: "-flto".}
|
|
|
|
template f(n: int) = discard card(default(set[range[0 .. (1 shl n) - 1]]))
|
|
f( 7)
|
|
f( 8)
|
|
f( 9)
|
|
f(10)
|
|
f(11)
|
|
f(12)
|
|
f(13)
|
|
f(14)
|
|
f(15)
|
|
f(16)
|