Odin
Odin copied to clipboard
Assertion bug when aliasing procedure multiple times in a specific way
Context
Odin: dev-2022-04:f92ffe60
OS: Windows 10 Unknown Edition (0000007d) (version: 21H2), build 19044.1645
CPU: Intel(R) Core(TM)2 Duo CPU P8600 @ 2.40GHz
RAM: 8086 MiB
Bug
In this directory structure:
alias.odin
package alias
import a "alias_pkg"
main :: proc() {
a.wait_vblank()
}
alias_pkg.odin
package alias_pkg
wait_vblank :: _wait_vblank
alias_pkg_windows.odin
//+build windows
package alias_pkg
import win32 "core:sys/windows"
_wait_vblank :: win32.DwmFlush
When compiling this error happens:
Odin\src\llvm_backend_proc.cpp(65): Assertion Failure: `entity->flags & EntityFlag_ProcBodyChecked` DwmFlush :: proc "stdcall" () -> HRESULT
but is still there
Update: as of 5d39780 this produces a different message:
Odin\src\llvm_backend_proc.cpp(72): Panic: DwmFlush :: proc "stdcall" () -> HRESULT (was parapoly: 0 0)
I have seen this bug too. Seems to happen when trying to resolve overloads but I'm not exactly sure when it gets triggered.