🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.modula2
Article #2958

Variable types

#2958
From: Bimal Shah
Date: Fri, 27 Oct 1995 08:48
24 lines
1153 bytes
Hi,

In Modula-2, is it possible to call a procedure which
has paramenters of AnyType ? e.g

PROCEDURE AddOne(VAR number:AnyType);
(* code here *)
END AddOne;

I require this, as the same operations need to be carried
out on different types... and i'd rather not have x procedures
for x different types.. as this looks really messy.

Any pointers on books, FAQ would also be great.

Thankyou.

 ----------------------------------------------------
|                 [Bimal Shah]                       |
| 'The measure of a persons intelligence is inversely|
| proportional to the amount of time they keep their |
| mouth open'                                        |
| (uni)  c2bs@dmu.ac.uk  (home) shah@foobar.co.uk    |
 ----------------------------------------------------
Technical Details
Message-ID: <46q6dp$dcv@macondo.dmu.ac.uk>
Path: arc1-ca.pugleaf.net!hilbert.cms.dmu.ac.uk!c2bs

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!hilbert.cms.dmu.ac.uk!c2bs
From: c2bs@dmu.ac.uk (Bimal Shah)
Newsgroups: comp.lang.modula2
Subject: Variable types
Date: 27 Oct 1995 08:48:57 GMT
Organization: De Montfort University, Leicester
Distribution: world
Message-ID: <46q6dp$dcv@macondo.dmu.ac.uk>
NNTP-Posting-Host: hilbert.cms.dmu.ac.uk
X-Newsreader: TIN [version 1.2 PL2]