home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.modula2
- Path: sparky!uunet!munnari.oz.au!metro!seagoon.newcastle.edu.au!wombat.newcastle.edu.au!eepjm
- From: eepjm@wombat.newcastle.edu.au (Peter Moylan)
- Subject: Re: Generic stack implementation
- Message-ID: <1993Jan11.171245.1@wombat.newcastle.edu.au>
- Lines: 14
- Sender: news@seagoon.newcastle.edu.au
- Organization: University of Newcastle, AUSTRALIA
- References: <36764.2B50C7C5@puddle.fidonet.org>
- Date: Mon, 11 Jan 1993 06:12:45 GMT
-
- In article <36764.2B50C7C5@puddle.fidonet.org>, Robert.Barton@p0.f6.n105.z1.fidonet.org (Robert Barton) writes:
- >
- > Why is type-casting non-portable?
-
- Try this:
- VAR c: CARDINAL; p: POINTER TO something;
- ...
- c := CARDINAL(p);
-
- It will work on machines for which a CARDINAL and a POINTER take the
- same amount of memory, but not on others.
-
- --
- Peter Moylan eepjm@wombat.newcastle.edu.au
-