mirror of
https://github.com/nim-lang/Nim.git
synced 2025-12-29 01:14:41 +00:00
18 lines
280 B
Nim
18 lines
280 B
Nim
discard """
|
|
errormsg: "cannot evaluate 'sizeof' because its type is not defined completely"
|
|
line: 9
|
|
"""
|
|
|
|
type
|
|
MyStruct {.importc: "MyStruct".} = object
|
|
|
|
const i = sizeof(MyStruct)
|
|
|
|
echo i
|
|
|
|
# bug #9868
|
|
proc foo(a: SomeInteger): array[sizeof(a), byte] =
|
|
discard
|
|
|
|
discard foo(1)
|