
Andre W B Furtado wrote:
When I use profiling with HOpenGL, the
file is empty (0 bytes) unless I change "mainLoop" for "return ()" in . Obviously, this program will terminate just after the window is created.
Alas, this is not HOpenGL-specific...
Does anyone know the reason for this? (I'm using HOpenGL-1.01, GHC-5.02.1 under Windows98 + cygwin).
The reason is that the only way to exit GLUT programs is via System.exitWith
or System.exitFailure. But GHC's RTS currently doesn't like calls to these
functions in callbacks, so the program terminates abnormally and nothing is
written to