🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.modula2
Article #1710

Initialisation code: When is it called?

#1710
From: Warwick Allison
Date: Mon, 28 Jan 1991 23:49
26 lines
1083 bytes
"A.def" exports a procedure "Do":

PROCEDURE Do(x:PROC);
(* Adds the given procedure to a list of procedures, all of which
   will be executed when user does... *)

"B.def" contains nothing.

"B.mod" has the following initialisation code:

BEGIN
	Do(SayHello);
END B.


Should a Modula-2 compiler know to include this module (I guess
it would have to be explicitly linked), and when would the init
code be executed?

Thanks very much, in advance.
--
________________________________________________________

	This .signature intentionally left blank
________________________________________________________
Technical Details
Message-ID: <7035@uqcspe.cs.uq.oz.au>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!munnari.oz.au!brolga!uqcspe!batserver.cs.uq.oz.au!warwick

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!munnari.oz.au!brolga!uqcspe!batserver.cs.uq.oz.au!warwick
From: warwick@batserver.cs.uq.oz.au (Warwick Allison)
Newsgroups: comp.lang.modula2
Subject: Initialisation code: When is it called?
Keywords: query question init
Message-ID: <7035@uqcspe.cs.uq.oz.au>
Date: 28 Jan 91 23:49:38 GMT
Sender: news@uqcspe.cs.uq.oz.au
Reply-To: warwick@batserver.cs.uq.oz.au
Lines: 26