Re: marking mystery code

Ted Dennison <>
14 Feb 1996 21:26:15 -0500

          From comp.compilers

Related articles
Re: Possible to write compiler to Java VM? (1996-01-29)
Re: marking mystery code (1996-02-13)
Re: marking mystery code (Ted Dennison) (1996-02-14)
Re: marking mystery code (1996-02-14)
Re: marking mystery code (1996-02-16)
Re: marking mystery code (1996-02-16)
Re: marking mystery code (Mitchell Perilstein) (1996-02-16)
Re: marking mystery code (Toon Moene) (1996-02-16)
Re: marking mystery code (1996-02-17)
[3 later articles]
| List of all articles for this month |

From: Ted Dennison <>
Newsgroups: comp.compilers
Date: 14 Feb 1996 21:26:15 -0500
Organization: Lockheed Martin Marine Systems
References: 96-01-116 96-02-138
Keywords: design

Robert Dewar wrote:
> Incidentally, the practice of marking suspicious code seems a good one
> to me. If code is being read by more than its author (often sadly not
> the case), then a reader will often wonder what something means, and
> not necessarily be able to tell if it is a bug, or if it needs more
> documentation, or perhaps some invariant that is assumed is not 100%
> right etc.

It seems like a good practice to me as well. But an even better
practice it to leave a comment describing what the code does
when you write it.

> In GNAT we use ??? for this purpose, and there are quite a few ???
> around the place. I suspect that nearly all large projects have
> numerous instances of code which merits the ??? mark, but they don't
> get marked.

When ever I come across such code, I figure out what it does and
either comment it, or rewrite it more clearly (or remove it). Is
this an uncommon practice?
T.E.D. (Structured programming bigot)
                                | Work - |
                                | Home - |
                                | URL - |
[It's uncommon in programs as large as GCC. -John]


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.