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,8143b93889fe9472 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit X-Received: by 10.66.84.100 with SMTP id x4mr617970pay.43.1359559727833; Wed, 30 Jan 2013 07:28:47 -0800 (PST) Path: s9ni26103pbb.0!nntp.google.com!border1.nntp.dca.giganews.com!border4.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!news-out.readnews.com!transit3.readnews.com!panix!bloom-beacon.mit.edu!newsswitch.lcs.mit.edu!nntp.TheWorld.com!.POSTED!not-for-mail From: Robert A Duff Newsgroups: comp.lang.ada Subject: Re: Ada standard and maximum line lengths Date: Wed, 30 Jan 2013 10:28:46 -0500 Organization: The World Public Access UNIX, Brookline, MA Message-ID: References: <8dfcf819-e1d0-4578-a795-a4bf724b5014@googlegroups.com> <5107b329$0$6556$9b4e6d93@newsspool4.arcor-online.net> <5107eaed$0$6566$9b4e6d93@newsspool4.arcor-online.net> <51080c38$0$6561$9b4e6d93@newsspool4.arcor-online.net> <51085776$0$6637$9b4e6d93@newsspool2.arcor-online.net> NNTP-Posting-Host: shell01.theworld.com Mime-Version: 1.0 X-Trace: pcls6.std.com 1359559727 5784 192.74.137.71 (30 Jan 2013 15:28:47 GMT) X-Complaints-To: abuse@TheWorld.com NNTP-Posting-Date: Wed, 30 Jan 2013 15:28:47 +0000 (UTC) User-Agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/21.3 (irix) Cancel-Lock: sha1:6SgA7bUmdpUoQilR2uKgigD0ckw= Content-Type: text/plain; charset=us-ascii Date: 2013-01-30T10:28:46-05:00 List-Id: Niklas Holsti writes: > To summarize, I think this thread started by asking why the ARM mentions > maximum line length at all. The discussion has shown that: > > - Ada 83 did not discuss line length or lexical-element length, so > compilers were in principle obliged to support any length, but perhaps > many compilers had limits motivated by "capacity limits". Right. > - Ada 95 introduced the lower bounds of 200 characters on lines and > lexical elements. Perhaps they were not meant to be independent, ... The wording is clear: the two requirements are independent. That was the intent. (I wrote those words, although I was opposed to adding the 200-char requirements.) >...and the > ACATS test require the compiler to support identifiers that are as long > as the longest possible line. Those tests are wrong, and they were wrong even for Ada 83. An Ada compiler is allowed to support unlimited line lengths. The ACATS requires the compiler to have a limit; that's wrong. It's also wrong to require that the two limits be the same. By "support unlimited line lengths" I mean no specific limit built into the compiler. Of course, there is always SOME limit -- the size of your disk limits how long a line can be, a (broken) OS might impose a limit, and if you compile something huge, the compiler might run out of memory. >...Therefore, in practice compilers use the > same limit (if any) for both, if I understood Randy correctly. Yes, they do. It's not the only time compiler writers have obeyed the ACATS, rather than disputing incorrect tests. That could be because it's a big hassle to dispute tests, and takes a long time, and in this case, it's trivial to obey the tests. It could also be because the compiler writer assumed the test was correct. > - Janus/Ada has a limit of around 250 characters on identifier length, > which Randy would find "annoying" to remove. I think the limit in GNAT is many thousands of characters. But sources written at AdaCore are limited to 79-character lines. > - The longest real-life identifier exhibited so far is from the Unicode > character names and is 73 characters. I'd prefer not to have such built-in limits. The fact that I've never seen an identifier longer than 73 characters doesn't change my mind. To argue for a built-in limit of 200 characters, I think you have to not only argue that "nobody needs lines longer than that", but also argue that there is some important advantage (efficiency? simplicity?), which I don't see here. - Bob