MODULE test_init ; (* m2SDL3 smoke test: SDL_Init(SDLInitVideo) / SDL_Quit round-trip plus SDL_WasInit mask check. Exit code 0 = pass, 1 = fail. SDL3 returns BOOLEAN (not int) from init calls. *) FROM SDL3 IMPORT SDL_Init, SDL_Quit, SDL_WasInit, SDLInitVideo; FROM libc IMPORT printf; VAR mask: CARDINAL; BEGIN IF NOT SDL_Init(SDLInitVideo) THEN printf("FAIL test_init: SDL_Init returned FALSE\n"); HALT(1) END; mask := SDL_WasInit(SDLInitVideo); IF mask = 0 THEN printf("FAIL test_init: SDL_WasInit mask is 0\n"); SDL_Quit; HALT(1) END; SDL_Quit; printf("PASS test_init (wasInit=%u)\n", mask) END test_init.