(****************************************************************) (* *) (* Gardens Point Modula-2 Library Definition *) (* *) (* *) (* (c) Copyright 1996 Faculty of Information Technology *) (* Queensland University of Technology *) (* *) (* Permission is granted to use, copy and change this *) (* program as long as the copyright message is left intact *) (* *) (****************************************************************) INTERFACE DEFINITION MODULE DtoA; IMPORT IMPLEMENTATION FROM "dtoa.o"; (* * Provides an interface to David Gay's dtoa software implemented in C * * double strtod(const char *s00); * char *dtoa(double d, int mode, int ndigits, int *decpt, char *sign); *) FROM Types IMPORT Int32; FROM SYSTEM IMPORT ADDRESS; VAR errno : Int32; CONST ERANGE = 34; (* Result too large *) PROCEDURE strtod(VAR s00 : ARRAY OF CHAR) : REAL; PROCEDURE dtoa(d : REAL; mode : Int32; ndigits : Int32; VAR decpt : Int32; VAR sign : BOOLEAN) : ADDRESS; END DtoA.