diff options
Diffstat (limited to 'gcc/m2/gm2-libs-iso/IOChanUtils.mod')
-rw-r--r-- | gcc/m2/gm2-libs-iso/IOChanUtils.mod | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/gcc/m2/gm2-libs-iso/IOChanUtils.mod b/gcc/m2/gm2-libs-iso/IOChanUtils.mod new file mode 100644 index 0000000..168fe0d --- /dev/null +++ b/gcc/m2/gm2-libs-iso/IOChanUtils.mod @@ -0,0 +1,28 @@ +IMPLEMENTATION MODULE IOChanUtils ; + +IMPORT IOChan, SFIO, RTio ; + + +(* + GetFileName - returns the filename as a new string associated + with chanid c. This string should be killed by + the caller. +*) + +PROCEDURE GetFileName (c: IOChan.ChanId) : String ; +BEGIN + RETURN SFIO.GetFileName (GetFile (c)) +END GetFileName ; + + +(* + GetFile - returns the FIO.File associated with ChanId c. +*) + +PROCEDURE GetFile (c: IOChan.ChanId) : File ; +BEGIN + RETURN RTio.GetFile (c) +END GetFile ; + + +END IOChanUtils. |