home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!wupost!sdd.hp.com!usc!rutgers!faatcrl!iecc!compilers-sender
- From: tmb@idiap.ch
- Newsgroups: comp.compilers
- Subject: Re: Adding garbage collection to C++
- Keywords: C, GC
- Message-ID: <92-08-092@comp.compilers>
- Date: 17 Aug 92 15:57:49 GMT
- References: <92-08-052@comp.compilers> <92-08-069@comp.compilers>
- Sender: compilers-sender@iecc.cambridge.ma.us
- Reply-To: tmb@idiap.ch
- Organization: IDIAP (Institut Dalle Molle d'Intelligence Artificielle
- Perceptive)
- Lines: 15
- Approved: compilers@iecc.cambridge.ma.us
-
- fjh@cs.mu.OZ.AU (Fergus Henderson) writes:
-
- >[C lets you hide pointers in inconvenient ways, e.g. writing them to
- >files or scrambling bytes in unions.]
-
- All the locations where a pointer is converted to an integer (via casts,
- unions, or memcpy) are detectable by the compiler. For any pointer that
- has ever been (mis-)treated in such a way, the corresponding memory can
- simply be exempted from garbage collection (e.g., by recording the pointer
- in some global table searched by the garbage collector).
-
- Thomas.
- --
- Send compilers articles to compilers@iecc.cambridge.ma.us or
- {ima | spdcc | world}!iecc!compilers. Meta-mail to compilers-request.
-