> From: Roger Racine <[log in to unmask]>
>
> At 01:54 AM 8/28/2003, Rick Duley wrote:
...
> >Is there any move afoot to review the Ada Style Book?
...
> >which gives you a fair chance of getting it all on a page without
> >word-wrap.  I can't see that this sort of thing is covered by the
> >standard and it would be nice if the people who devise the
> >"reformat" routines for IDEs had something standard to work to.

Our project (and my own code) is written using GNAT. 99% of the time I
just let emacs ada-mode do the indenting for me and compile with style
checking on (-gnaty). I have great difficulty persuading people to do
this *and fix the style errors*. I guess the only aproach that's going
to work is to do code reviews from compiler-generated listings
(compiled with -gnatfly, perhaps).

> I think I prefer a more heuristic approach, rather than a single
> standard, in this area.  My logic for formatting something like this
> (if I were doing it by hand) would be:

I wrote a formatter (for Coral 66) ages ago, it worked by identifying
optional and mandatory line breaks and fold points (both single fold
points and ones that must all be taken if any is, such as procedure
parameters; either all on the same line, or each on its own line) in
much the same way as you describe. But it required a special perser
generator, and was written for VAX/VMS .. and I never managed to do it
for Ada, cos the parser generator was very simpleminded.

> Of course, then there are those (with young eyes) who say to just
> use a 6-point font (giving about 266 characters per line on a high
> resolution screen). :-)

Perhas we could fix text editors so they _won't_ display more than 80
columns at a time!