[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Low-level vs. High-level programming
- Subject: Re: Low-level vs. High-level programming
- From: pausch@saaf.se (Paul Schlyter)
- Date: Tue, 24 Jun 2003 07:52:36 +0000 (UTC)
- Newsgroups: comp.sys.cbm, comp.sys.apple2, rec.games.video.classic, comp.os.cpm
- Organization: Svensk Amat|rAstronomisk F|rening
- References: <b3qo6h$5ar$1@barad-dur.nas.com> <EHrJa.16254$bH3.337@fe02.atl2.webusenet.com> <bd696r$15en$1@merope.saaf.se> <bd6g35$tte$1@barad-dur.nas.com>
- Xref: archiver1.google.com comp.sys.cbm:59255 comp.sys.apple2:31841 rec.games.video.classic:59370 comp.os.cpm:13529
In article <bd6g35$tte$1@barad-dur.nas.com>,
White Flame \(aka David Holz\) <whiteflame52@y.a.h.o.o.com> wrote:
> "Paul Schlyter" <pausch@saaf.se> wrote in message
> news:bd696r$15en$1@merope.saaf.se...
>> unsigned int memory_address = <address_of_memory_mapped_HW-device>;
>
> That's fairly ugly, and isn't guaranteed to work, since there's no
> requirements that ints be as wide as pointers.
In such a situation, use a long int instead.....
> If memory_address were a void*, it would be quite kosher.
Wouldn't help much, since the value of the address would still have
to be specified as a constant, and there are no (void *) constants in C.
--
----------------------------------------------------------------
Paul Schlyter, Grev Turegatan 40, SE-114 38 Stockholm, SWEDEN
e-mail: pausch at stockholm dot bostream dot se
WWW: http://www.stjarnhimlen.se/
http://home.tiscali.se/pausch/