🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

1 total messages Started by Joseph Manning Sat, 18 Oct 1986 17:19
Bugs in DECWRL (Powell) Modula-2 Compiler
#582
Author: Joseph Manning
Date: Sat, 18 Oct 1986 17:19
41 lines
2298 bytes
Here are some bugs that I've come across using the DECWRL Modula-2 compiler
running under UNIX 4.2 / 4.3 BSD :

   [1]  " FLOAT( c ) "  returns garbage when  c  is a CARDINAL CONST

   [2]  " FOR c := lo TO hi DO s END ", with  c : CARDINAL, lo >= 0, hi < 0
        will execute  s  ONCE, with c = lo, instead of just falling through
        (it does work correctly when c : INTEGER, but there are cases where
        CARDINAL is logically more appropriate)

   [3]  NEGATIVE whole numbers may be freely assigned to CARDINAL VARs;  no
        complaint even when compiled with the  -C  and  -sc  options  (!!!)

   [4]  FIRST( CARDINAL ) = -2147483648, instead of 0

   [5]  RETURN  inside a  WITH  from inside a function procedure causes the
        compiler to complain that the "Function does not end with a return"
        and no code is generated.

   [6]  A CASE statement with a BOOLEAN selector CRASHES the compiler !

Although some of these constructs may appear unusual, that's not the point;
the fact is that they should work correctly but do not.

Each of these bugs caused me varying degrees of grief / distress / confusion
before tracking it down and isolating it.  I'm posting this list to the net
hoping that other users of is compiler will be aware of these problems and
avoid the same difficulties.

If anyone has come across any other bugs, please let me know !!!

I'm new to net.lang.mod2, so apologies if this topic is old ...

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

Joseph Manning

Dept of Computer Sciences, Purdue University, West Lafayette, IN 47906, USA

InterNet: jbm @ mordred.cs.purdue.edu
UUCP    : ...{allegra,decwrl,ihnp4}!purdue!jbm
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads