From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,8b756d9a0afb052a X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!newshub.sdsu.edu!elnk-nf2-pas!newsfeed.earthlink.net!stamper.news.pas.earthlink.net!newsread3.news.pas.earthlink.net.POSTED!a6202946!not-for-mail From: "Jeffrey R. Carter" Organization: jrcarter at acm dot org User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.12) Gecko/20050915 X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Quick question about Ada code formatting. References: In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: Date: Sat, 18 Feb 2006 20:21:47 GMT NNTP-Posting-Host: 67.150.79.75 X-Complaints-To: abuse@earthlink.net X-Trace: newsread3.news.pas.earthlink.net 1140294107 67.150.79.75 (Sat, 18 Feb 2006 12:21:47 PST) NNTP-Posting-Date: Sat, 18 Feb 2006 12:21:47 PST Xref: g2news1.google.com comp.lang.ada:2963 Date: 2006-02-18T20:21:47+00:00 List-Id: Peter C. Chapin wrote: > My_Procedure (X, Y, Z); > A := My_Function (B); This is what I like, if it will fit on one line, except I like named notation for procedures. > My_Procedure > (Very_Long, Argument_List, With_Many, Arguments); This is what I like if it won't fit on one line with the procedure name, but will on a separate line, with the caveat noted above. If it won't fit on a separate line, then I like Procedure_Name (First_Param => First_Param, Second_Param => Second_Param, ... Last_Param => Last_Param); > In other communities (C/C++) it is more common to leave the space out > and also to leave the opening '(' on the same line as the procedure > name. There's little from the C/++ world worth adopting. > P.S. Is there an accepted indentation depth among Ada programmers? I've > seen three spaces in several places and I notice both Ada-mode in Emacs > and GPS use three spaces by default. 2-4 is an acceptable range, and 3 is in the middle of that. I personally use 3. -- Jeff Carter "Mr. President, we must not allow a mine-shaft gap!" Dr. Strangelove 33