Article View: comp.lang.modula2
Article #3188Re: RE: GNU Modula-2 compiler for suns
From: Dan Eldred
Date: Thu, 25 Jan 1996 01:08
Date: Thu, 25 Jan 1996 01:08
38 lines
2284 bytes
2284 bytes
In article <j.w.kalkman.1460.000B16FA@student.utwente.nl>, j.w.kalkman@student.utwente.nl <j.w.kalkman@student.utwente.nl> wrote: >In article <30FE8882.41C67EA6@zeus.hud.ac.uk> Satpal <c9502007@zeus.hud.ac.uk> writes: > >>Does any one out there know where I can get a free modula-2 compiler for >>a sun workstation. >>Please reply to >>c9502007@zeus.hud.ac.uk > >>Thanx > >mtc, the modula-to-c translator, was set up to run on suns, I think. > >I know it's not a compiler, but it's something, right? > mtc works well for me. I've successfully compiled it under SunOS, Solaris, Linux and MacMiNT on a macintosh! I haven't however been successful in getting it compiled under Think C on a mac, though I got real close before I moved over to Linux. It's got a nice makefile generator also that simplifies life. mtc is close to the Mocka dialect. I'm particularly pleased at how readable the generated code is. In fact, this makes it real easy to handle a mixture of C and Modula-2 code. For example, I can use C's printf statements directly in the mtc code, since I have declared them as foreign interfaces. Or I can link directly with all the C libraries in a Unix system. And if there's something low level that's difficult to accomplish with the higher-level protections of Modula-2, I can just write the low level stuff in C. One stress test for mtc was that I successfully compiled the graphics libraries distributed with gpm, among other things. In fact, I have turned the tables, and I use my modified version of this library for many simple graphics tasks from C programs. My main wish is that it would be nice to be able to turn on array bounds checking somehow. I think o2c (Oberon to C) has such an option that inserts bounds checking code into the generated C code. Cheers, Dan.
Technical Details
Message-ID:
<4e6l7b$5oe@rrunner.jpl.nasa.gov>Path:
arc1-ca.pugleaf.net!elroy.jpl.nasa.gov!llyene!nobodyReferences:
<30FE8882.41C67EA6@zeus.hud.ac.uk> <j.w.kalkman.1460.000B16FA@student.utwente.nl>Show Full Headers
Complete Article Headers
Newsgroups: comp.lang.modula2 Path: arc1-ca.pugleaf.net!elroy.jpl.nasa.gov!llyene!nobody From: eldred@rrunner.jpl.nasa.gov (Dan Eldred) Subject: Re: RE: GNU Modula-2 compiler for suns Message-ID: <4e6l7b$5oe@rrunner.jpl.nasa.gov> Sender: news@llyene.jpl.nasa.gov Organization: Jet Propulsion Laboratory, Pasadena, CA References: <30FE8882.41C67EA6@zeus.hud.ac.uk> <j.w.kalkman.1460.000B16FA@student.utwente.nl> Date: Thu, 25 Jan 1996 01:08:59 GMT