home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: gnu.utils.bug
- Path: sparky!uunet!cis.ohio-state.edu!src.honeywell.com!tap
- From: tap@src.honeywell.com (Thomas A Peterson)
- Subject: indent produces warnings
- Message-ID: <9301061908.AA13372@aristotle.src.honeywell.com>
- Sender: gnulists@ai.mit.edu
- Organization: GNUs Not Usenet
- Distribution: gnu
- Date: Wed, 6 Jan 1993 19:08:44 GMT
- Approved: bug-gnu-utils@prep.ai.mit.edu
- Lines: 46
-
- Program : indent
- Version: 1.6
- Machine: SPARCstation IPX
- OS: SunOS4.1.1
- Description:
-
- The following chunk of code causes indent to produce warnings.
-
- aristotle: cc -c indent_fail.c
- aristotle: indent indent_fail.c
- indent_fail.c: 6: Unbalanced parens
- indent_fail.c: 6: Extra )
- indent_fail.c: 17: Unbalanced parens
- indent_fail.c: 17: Extra )
- aristotle:
-
- NOTE: I have no idea why C allows me to place a complete declaration
- in a cast expression but it does.
-
-
- /* indent_fails.c */
-
- void main()
- {
- int a, j;
-
- j =1;
- a = (enum colors {red1, white1}) 1;
- {
- enum colors color;
- color = white1;
- }
- }
-
- void main1()
- {
- int a;
-
- a = (int) (struct help { int a;} *) 1;
- {
- typedef struct help help_t;
- help_t trash;
- trash.a = 14;
- }
- }
-
-