Files
compiler-explorer/test/odin/add_require.odin.expected
Waqar Ahmed 54ea096e1a odin: require main function (#7314)
In optimized build, odin inlines the world and even ends up inlining the
user visible `main` function into the entry point main. The result is
empty asm output which is confusing. Thus, @require main so that the
compiler doesn't inline user visible main function

 #7210
2025-01-29 10:41:03 -06:00

19 lines
194 B
Plaintext

package main
import "core:fmt"
@(require) test_proc :: proc() {
}
@(require)
test_proc1 :: proc() {
}
@require
test_proc2 :: proc() {
}
@(require) main :: proc() {
fmt.println("asd")
}