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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,21a8034919747a69 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news4.google.com!border1.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!novia!newsfeed.icl.net!colt.net!feeder.news-service.com!newsfeed.freenet.de!news.germany.com!feeder.news.tin.it!spool.news.tin.it!not-for-mail From: Francesco Bochicchio Subject: Re: Splitting packages in per-procedure separate files Date: Mon, 12 Feb 2007 19:42:56 +0100 User-Agent: Pan/0.14.2.91 (As She Crawled Across the Table (Debian GNU/Linux)) Message-Id: Newsgroups: comp.lang.ada References: <2007021017501616807-sjs@essexacuk> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 8bit Organization: TIN.IT (http://www.tin.it) X-Comments: Please send technical notifications to newsmaster@tin.it NNTP-Posting-Host: 82.55.255.215 X-Trace: 1171305776 reader3.news.tin.it 10477 82.55.255.215:1434 X-Complaints-To: Please send abuse reports to abuse@tin.it Xref: g2news2.google.com comp.lang.ada:9290 Date: 2007-02-12T19:42:56+01:00 List-Id: Il Mon, 12 Feb 2007 05:45:51 -0500, Stephen Leake ha scritto: > Francesco Bochicchio writes: > >> What I have is an application consisting of a dozen different >> packages. Now the standard mandates: >> >> - one name_package.ads for package public declarations >> - one name_package.adb for package private declarations (including >> separate declarations for all procedures) >> - one name_package-name_procedure.adb for each procedure in the package >> >> Some of the coders have actually followed the standards, some have not, >> putting all the procedure code inside the name_package.adb file. Now I >> have to split these files ( about half of the packages, so probably 10000 >> line of codes, not the 20000 initially stated ). > > In general, I approve of organizations enforcing coding standards; > they increase overall productivity. > > However, in this situation it's appropriate to consider whether this > coding standard should be changed instead. I agree. Unfortunately our client does not - at least on this specific issue (they have relaxed other standards ... ). > ... > What is the rationale for putting _every_ procedure in a separate file? > In theory, for readability. In theory. In my experience, I found that the code readability depends on the IDE you are using. With simple editors (say emacs or UltraEdit) I feel more comfortable to have a whole package in a single file. With complete IDE (say GPS or AdaMulti) it does not matter much one way or the other, since the file structure is hidden behind the project structure. Anyway I am not in the position to cange the standards ... > Why do some coders choose to not follow the standard? > It happens in messy projects, and the one in question has been _very_ messy ... Ciao ------ FB