Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!utgpu!water!watmath!clyde!rutgers!labrea!decwrl!sun!calma!clark From: clark@calma.UUCP Newsgroups: comp.unix.wizards Subject: Re: indent bug Message-ID: <707@calma.uucp> Date: Sat, 14-Nov-87 12:21:24 EST Article-I.D.: calma.707 Posted: Sat Nov 14 12:21:24 1987 Date-Received: Fri, 20-Nov-87 23:38:27 EST References: <10266@brl-adm.ARPA> Reply-To: clark@calma.UUCP (Al Clark) Organization: GE/Calma Co., R&D Systems Engineering, Milpitas, CA Lines: 29 In article <10266@brl-adm.ARPA> eichelbe@nadc.arpa (J. Eichelberger) writes: >We are running 4.3 BSD UNIX on a VAX 11/780. > >The following bug has been found when "indent" was run. No flags were >specified. Just "indent input.c output.c". (detailed description deleted >Notice the change in the line "i=!i;" to "i != i;". I know the workaround, (more deleted) > Jon Eichelberger > eichelbe@NADC.ARPA I am only speculating, but the "=!" to "!=" change may be a feature, not a bug. For example, the old form of "+=" and "-=" was "=+" and "=-". At least for some compilers, the older form is still honored, presumably in the name of backwards compatabil- ity. In those cases expressions like "a=-1" get treated as though they were "a-=1". I always leave a space between an equal sign and a following operator, just to be sure. It is interest- ing that indent, at least in this case, treated the "=!" just as the "backwards compatible" compiler would, but makes the in- terpretation obvious. So I would think of it as a feature, not a bug, in that it makes the output non-ambiguous. (In passing, note that the "=+" construct is still honored by all the versions of "bc" that I use, and is the only construct honored by the "bc" in my Unisoft sytem.) -- Al Clark - {ucbvax,sun,...}calma!clark ...calma!gewest!aclark!al NOTE: The calma account is a courtesy account; I am not employed by calma.