Version
110.99.2
Operating System
OS Version
No response
Processor
No response
Component
Basis Library
Severity
Major
Description of the problem
When using SML/NJ interactively, the SML/NJ REPL shows an error whenever there is a result of type Posix.FileSys.ST.stat.
For example, when evaluating Posix.FileSys.stat "/etc/passwd";
Standard ML of New Jersey (64-bit) v110.99.2 [built: Thu Jan 23 12:34:56 2022]
- Posix.FileSys.stat "/etc/passwd";
[autoloading]
[library $SMLNJ-BASIS/basis.cm is stable]
[library $SMLNJ-BASIS/(basis.cm):basis-common.cm is stable]
[autoloading done]
val it =
ST
{atime=TIME {usec=1652879341508064},ctime=TIME {usec=1647945818121959},
unexpected exception (bug?) in SML/NJ: Representation [Representation]
raised at: Basis/Implementation/Unsafe/target64-object.sml:111.19-111.33
../compiler/TopLevel/print/ppobj.sml:85.45
../compiler/TopLevel/print/ppobj.sml:373.24
../compiler/TopLevel/print/ppobj.sml:373.24
../compiler/TopLevel/print/ppobj.sml:373.24
../compiler/TopLevel/interact/evalloop.sml:45.54
-
Transcript
No response
Expected Behavior
No response
Steps to Reproduce
No response
Additional Information
No response
Email address
No response
Comments from smlnj-gforge
Original smlnj-gforge bug number 310
Submitted on 2022-05-19 at 09:48:00
comment by @JohnReppy on 2022-05-20 14:20:00 +000 UTC
The issue seems to be with the dev field of the stat record.
- Posix.FileSys.ST.dev(Posix.FileSys.stat "/etc/passwd");
unexpected exception (bug?) in SML/NJ: Representation [Representation]
raised at: Basis/Implementation/Unsafe/target64-object.sml:111.19-111.33
../compiler/TopLevel/print/ppobj.sml:85.45
../compiler/TopLevel/print/ppobj.sml:373.24
../compiler/TopLevel/interact/evalloop.sml:45.54
This field is represented as a singleton data constructor that wraps a Word64.word value.
comment by @JohnReppy on 2022-05-20 14:30:00 +000 UTC
Fixed for 2022.1 and 110.99.3. The fix is was to the isUbxTy function in the ppobj.sml file.
Version
110.99.2
Operating System
OS Version
No response
Processor
No response
Component
Basis Library
Severity
Major
Description of the problem
When using SML/NJ interactively, the SML/NJ REPL shows an error whenever there is a result of type Posix.FileSys.ST.stat.
For example, when evaluating Posix.FileSys.stat "/etc/passwd";
Transcript
No response
Expected Behavior
No response
Steps to Reproduce
No response
Additional Information
No response
Email address
No response
Comments from smlnj-gforge
Original smlnj-gforge bug number 310
Submitted on 2022-05-19 at 09:48:00
comment by @JohnReppy on 2022-05-20 14:20:00 +000 UTC
The issue seems to be with the
devfield of thestatrecord.This field is represented as a singleton data constructor that wraps a Word64.word value.
comment by @JohnReppy on 2022-05-20 14:30:00 +000 UTC
Fixed for 2022.1 and 110.99.3. The fix is was to the
isUbxTyfunction in theppobj.smlfile.