From: julian.fondren@gmail.com
Subject: gnatpp parameter alignment
Date: Tue, 27 Nov 2018 16:34:00 -0800 (PST)
Date: 2018-11-27T16:34:00-08:00 [thread overview]
Message-ID: <3bec5f4b-a5e4-408a-b9e8-9bdd18ce0671@googlegroups.com> (raw)
Hello comp.lang.ada,
I thought I'd always use gnatpp for styling, but I've found this
formatting result that I don't like at all, and which seems to come up
a lot in my code (so often that !pp formatting escapes would be a
pain):
function waitpid (Pid : Integer; Wstatus : System.Address;
Options : Integer) return Integer;
What I'd prefer is that, if parameters take up more than one line,
that they just switch to an entirely vertical formatting, something
like:
function waitpid (Pid : Integer;
Wstatus : System.Address;
Options : Integer) return Integer;
or
function waitpid
( Pid : Integer;
Wstatus : System.Address;
Options : Integer) return Integer;
Many other variations would be acceptable, as long as there aren't
multiple parameters on a line and *also* parameters across multiple
lines, especially with that long-distance horizontal alignment that
makes "Options" look like it's unrelated to the function definition
around it.
I've looked through gnatpp's flags and didn't find anything for
this. I like horizontal alignment in general, and I can deal with most
of the rest of gnatpp's results, so I don't want to turn off huge
swaths of gnatpp formatting. I just want this one case to not visually
suggest that a three-argument function has only two arguments.
Thanks.
next reply other threads:[~2018-11-28 0:34 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-28 0:34 julian.fondren [this message]
2018-11-28 7:37 ` gnatpp parameter alignment briot.emmanuel
2018-11-28 7:56 ` Mark Lorenzen
2018-11-28 8:42 ` Simon Wright
2018-11-28 9:02 ` Simon Wright
2018-11-28 13:50 ` Simon Wright
2018-11-28 14:19 ` julian.fondren
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox