bug report: 20100608 macintel raises SysErr in basis library if run from a bundle
Bernard Berthomieu <[email protected]>
| Newsgroups | gmane.comp.lang.ml.mlton.devel |
|---|---|
| Message-ID | <[email protected]> |
Hello,
Under some special circumstances (see below), 20100608 macintel
raises SysErr in basis library.
The problem seems to be with the value of stdIn in that context.
--
For reproducing the bug, I attached an archive containing:
an sml file: mlapp.sml
a mac bundle: nd.app
The bundle (nd.app) embeds a tcl/tk interpreter running
the tcl script: nd.app/Contents/Resources/Scripts/AppMain.tcl
The script executes the sml application "mlapp" (in the same directory),
obtained from the sml file attached by: mlton mlapp.sml.
When double-clicked or run by "open nd.app" in a terminal, nd.app
pops a dialog with message "hello" if the call of mlapp is successfull,
or an error message otherwise. If mlapp.sml refers to TextIO.stdIn, then
the following message shows up:
unhandled exception: SysErr
MLton bug: unhandled exception in Basis Library
Please send a bug report tp [email protected].
If the line "TextIO.stdIn" is removed in mlapp.sml (and the resulting
mlapp placed in directory nd.app/Contents/Resources/Scripts), then
the call succeeds and the dialog shows hello.
If AppMain.tcl is run directly from a terminal by "wish AppMain.tcl"
in directory nd.app/Contents/Resources/Scripts, then SysErr is not
raised.
Bernard.
--
Bernard Berthomieu
LAAS / CNRS
7, avenue du Colonel Roche
31077 Toulouse Cedex
France
[email protected]
http://www.laas.fr/~bernard
phone +33/(0)5 61 33 63 63
fax +33/(0)5 61 33 64 11
bug2.tar
(application/x-tar, 742.7 KB) - not displayed