🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.modula2
Article #3670

(none)

#3670
From: Thomas Habernoll
Date: Mon, 18 May 1987 20:18
31 lines
2196 bytes
> [ from Gernot Heiser, regarding the DEC compiler: ]
>    - identifiers imported in the definition module are not known in the
>      implementation module, they must be imported again. This will generate
>a
>      compile-time error in most other Modula-2 systems
> [ and in another letter as explanation: ]
>Imports ARE declarations! PIM2 ed2 p 143 (sorry, I don't have ed3 at hand, but
>there should be no difference concerning this point):
>"Every identifier occuring in a program must be introduced by a declaration,
>unless it is a standard identifier."
>This means, importing an identifier into a definition module declares this
>identifier, and hence makes it "available in the corresponding implementation
>module without explicit import." (PIM ed2 p 164)

Iff imports are declarations, the above assumption will be right. But
I can't find where this is defined. An import is a way to extend
the scope of a declaration, and therefore makes the declared identifier
visible in the importing module. But it don't move the location of
the declaration.

Both the TDI compiler for Atari-ST and our compiler on IBM/CMS
share my opinion. This isn't very astonishing because they have
the same grandfather: the ETH Zurich 4-pass compiler. And because
our CMS compiler is very similar to the Cambridge system which
runs on several 68K Unix boxes here, I have severe doubts that
the Cambridge compiler will show a different behaviour (which was implied
by your comparsion of the DEC and the Cambridge compiler).

  Thomas

Technical University Berlin               BITNET: HABERNOL@DB0TUI11
Technical Details
Message-ID: <8705181937.AA09466@cayuga.cs.rochester.edu>
Path: arc1-ca.pugleaf.net!utzoo!mnetor!seismo!rutgers!ames!ucbcad!ucbvax!DB0TUI11.BITNET!HABERNOL
References: <SMTP@WISCVM>

Show Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: arc1-ca.pugleaf.net!utzoo!mnetor!seismo!rutgers!ames!ucbcad!ucbvax!DB0TUI11.BITNET!HABERNOL
From: HABERNOL@DB0TUI11.BITNET (Thomas Habernoll)
Newsgroups: comp.lang.modula2
Subject: (none)
Message-ID: <8705181937.AA09466@cayuga.cs.rochester.edu>
Date: Mon, 18-May-87 16:18:12 EDT
Article-I.D.: cayuga.8705181937.AA09466
Posted: Mon May 18 16:18:12 1987
Date-Received: Tue, 19-May-87 05:46:33 EDT
References: <SMTP@WISCVM>
Sender: daemon@ucbvax.BERKELEY.EDU
Distribution: world
Organization: The ARPA Internet
Lines: 31