Unsafe functions such as unsafe.Alignof, unsafe.Offsetof and unsafe.Sizeof can be used for type declarations early on during compile, and as such, must be treated as builtins returning constants at compile time. It is still necessary to explicitely enable unsafe support in yaegi.
Unsafe functions such as
unsafe.Alignof
,unsafe.Offsetof
andunsafe.Sizeof
can be used for type declarations early on during compile, and as such, must be treated as builtins returning constants at compile time. It is still necessary to explicitely enable unsafe support in yaegi.The support of
unsafe.Add
has also been added.Fixes #1544.