CLibraryDefs: DEFINITIONS = { -- Types CChar: TYPE = INTEGER; CInt: TYPE = LONG INTEGER; CString: TYPE = LONG POINTER TO INTEGER; FILE: TYPE = LONG INTEGER; -- Constants cNULL: LONG INTEGER = 0; EOF: CInt = -1; stdin: FILE = 0; stdout: FILE = 1; stderr: FILE = 2; -- System Calls chdir: PROCEDURE [directoryName: CString] RETURNS [returnCode: CInt]; chmod: PROCEDURE [fileName: CString, fileMode: CInt] RETURNS [returnCode: CInt]; close: PROCEDURE [fileDescriptor: FILE] RETURNS [returnCode: CInt]; creat: PROCEDURE [fileName: CString, fileMode: CInt] RETURNS [fileDescriptor: FILE]; dup: PROCEDURE [oldFileDescriptor: FILE] RETURNS [newFileDescriptor: FILE]; dup2: PROCEDURE [fileDescriptor1, fileDescriptor2: FILE] RETURNS [fileDescriptor: FILE]; execv: PROCEDURE [codeFileName: CString, argv: LONG POINTER TO CString] RETURNS [returnCode: CInt]; exit: PROCEDURE [returnCode: CInt]; fork: PROCEDURE [] RETURNS [processDescriptor: CInt]; fstat: PROCEDURE [fileDescriptor: FILE, buffer: LONG POINTER] RETURNS [returnCode: CInt]; link: PROCEDURE [fileName1, fileName2: CString] RETURNS [returnCode: CInt]; lseek: PROCEDURE [fileDescriptor: FILE, offset, whence: CInt] RETURNS [filePosition: CInt]; open: PROCEDURE [fileName: CString, fileMode: CInt] RETURNS [fileDescriptor: FILE]; pipe: PROCEDURE [fileDescriptorArray: LONG POINTER TO FILE] RETURNS [returnCode: CInt]; read: PROCEDURE [fileDescriptor: FILE, buffer: CString, nBytes: CInt] RETURNS [nBytesRead: CInt]; signal: PROCEDURE [signalNumber: CInt, functionToCall: LONG POINTER] RETURNS [returnCode: CInt]; stat: PROCEDURE [fileName: CString, buffer: LONG POINTER] RETURNS [returnCode: CInt]; time: PROCEDURE [timeBuffer: LONG POINTER TO CInt] RETURNS [timeValue: CInt]; umask: PROCEDURE [complementedMode: CInt]; unlink: PROCEDURE [fileName: CString] RETURNS [returnCode: CInt]; wait: PROCEDURE [returnCode: LONG POINTER TO CInt] RETURNS [processDescriptor: CInt]; write: PROCEDURE [fileDescriptor: FILE, buffer: CString, nBytes: CInt] RETURNS [nBytesWritten: CInt]; -- Library Functions and Procedures abs: PROCEDURE [i: CInt] RETURNS [AbsI: CInt]; atoi: PROCEDURE [numberPointer: CString] RETURNS [number: CInt]; atol: PROCEDURE [numberPointer: CString] RETURNS [number: CInt]; ctime: PROCEDURE [time: LONG POINTER TO CInt] RETURNS [timeString: CString]; fclose: PROCEDURE [stream: FILE]; fflush: PROCEDURE [stream: FILE]; fgetc: PROCEDURE [stream: FILE] RETURNS [char: CChar]; fgets: PROCEDURE [string: CString, length: CInt,stream: FILE] RETURNS [sameString: CString]; fopen: PROCEDURE [fileName, type: CString] RETURNS [stream: FILE]; fputc: PROCEDURE [char: CChar, stream: FILE]; fputs: PROCEDURE [string: CString, stream: FILE]; fprintf: PROCEDURE [stream: FILE, format: CString, N1: LONG UNSPECIFIED _ 17777777777B, N2: LONG UNSPECIFIED _ 17777777777B, N3: LONG UNSPECIFIED _ 17777777777B, N4: LONG UNSPECIFIED _ 17777777777B, N5: LONG UNSPECIFIED _ 17777777777B, N6: LONG UNSPECIFIED _ 17777777777B, N7: LONG UNSPECIFIED _ 17777777777B, N8: LONG UNSPECIFIED _ 17777777777B]; fread: PROCEDURE [buffer: LONG POINTER, sizeOfBufferItems, nItems: CInt, stream: FILE] RETURNS [itemsRead: CInt]; free: PROCEDURE [LONG POINTER]; freopen: PROCEDURE [fileName, type: LONG POINTER TO INTEGER, oldStream: FILE] RETURNS [newStream: FILE]; fscanf: PROCEDURE [stream: FILE, format: CString, N1: LONG POINTER _ NIL, N2: LONG POINTER _ NIL, N3: LONG POINTER _ NIL, N4: LONG POINTER _ NIL, N5: LONG POINTER _ NIL, N6: LONG POINTER _ NIL, N7: LONG POINTER _ NIL, N8: LONG POINTER _ NIL]; fseek: PROCEDURE [stream: FILE, offset, ptrName: CInt] RETURNS [itemsRead: CInt]; fwrite: PROCEDURE [buffer: LONG POINTER, sizeOfBufferItems, nItems: CInt, stream: FILE] RETURNS [itemsWritten: CInt]; getc: PROCEDURE [stream: FILE] RETURNS [char: CChar]; getchar: PROCEDURE [] RETURNS [char: CChar]; gets: PROCEDURE [string: CString] RETURNS [sameString: CString]; isalpha: PROCEDURE [char: CChar] RETURNS [logical: CInt]; isdigit: PROCEDURE [char: CChar] RETURNS [logical: CInt]; islower: PROCEDURE [char: CChar] RETURNS [logical: CInt]; isupper: PROCEDURE [char: CChar] RETURNS [logical: CInt]; malloc: PROCEDURE [size: CInt] RETURNS [LONG POINTER]; perror: PROCEDURE [string: CString]; printf: PROCEDURE [format: CString, N1: LONG UNSPECIFIED _ 17777777777B, N2: LONG UNSPECIFIED _ 17777777777B, N3: LONG UNSPECIFIED _ 17777777777B, N4: LONG UNSPECIFIED _ 17777777777B, N5: LONG UNSPECIFIED _ 17777777777B, N6: LONG UNSPECIFIED _ 17777777777B, N7: LONG UNSPECIFIED _ 17777777777B, N8: LONG UNSPECIFIED _ 17777777777B]; putc: PROCEDURE [char: CChar, stream: FILE]; putchar: PROCEDURE [char: CChar]; puts: PROCEDURE [string: CString, stream: FILE]; scanf: PROCEDURE [format: CString, N1: LONG POINTER _ NIL, N2: LONG POINTER _ NIL, N3: LONG POINTER _ NIL, N4: LONG POINTER _ NIL, N5: LONG POINTER _ NIL, N6: LONG POINTER _ NIL, N7: LONG POINTER _ NIL, N8: LONG POINTER _ NIL]; setbuf: PROCEDURE [stream: FILE, buffer: LONG POINTER]; strcat: PROCEDURE [s1, s2: CString] RETURNS [result: CString]; strcmp: PROCEDURE [s1, s2: CString] RETURNS [result: CInt]; strcpy: PROCEDURE [s1, s2: CString] RETURNS [result: CString]; strlen: PROCEDURE [s1, s2: CString] RETURNS [stringLength: CInt]; toupper: PROCEDURE [cin: CChar] RETURNS [cout: CChar]; -- Artifacts of the simulation of Unix in Tajo Error: PROCEDURE [s: LONG STRING]; GetArgs: PROCEDURE [argc: LONG POINTER TO LONG INTEGER, argv: LONG POINTER TO LONG POINTER TO LONG POINTER TO INTEGER]; }.