Usenet comp.sys.dec (1990-2013)
 help / color / mirror / Atom feed
From: mark@chem.uwa.edu.au (Mark C Favas - SysAd)
Subject: DEC C compiler bug - Digital Unix 4.0
Date: 1996/08/06	[thread overview]
Message-ID: <mark.839311868@declan> (raw)



I've just isolated the following code that tickles a bug in DEC's cc compiler.
Hardware: Digital AlphaStation 500/333
Operating System: Digital Unix V4.0 (rev 386)
Compiler: DEC C V5.2-023

The code fragment:

#define PPROTO Py_PROTO
#define Py_PROTO(x) x
static int halfbinop PPROTO((int *, int *, char *, int **,
			    int * (*) PPROTO((int *, int *)), int ));

when compiled with "cc -c PROTO_bug.c" produces the following error message:

cc: Error: PROTO_bug.c, line 3: Missing ")".
static int halfbinop PPROTO((int *, int *, char *, int **,
---------------------^

If I compile with the flag "-oldc", there is no error. The default is to use the
GEM C compiler (-newc), so it looks as though the error is in 
/usr/lib/cmplrs/cc/gemc_cc. The error also occurs if I use the "-migrate" flag
to invoke the GEM C compiler. I can compile this on another machine running
Digital Unix V3.2 and an earlier version of the GEM compiler without error.

Interestingly, if I change either of the PPROTO keywords in the forward
definition of halfbinop to Py_PROTO it compiles without error.

Has anyone come across this one, or got any comments to make (DEC?)?

	Thanks,
		Mark


--
Email  - mark@chem.uwa.edu.au      ,-_|\                           Mark C Favas
Phone  - +61 9 380 3482           /     \               Department of Chemistry
Fax    - +61 9 380 1005      ---> *_,-._/   The University of Western Australia
                                       v                               Nedlands
Loc    - 31.97 S, 115.81 E                               Western Australia 6009



             reply	other threads:[~1996-08-06  4:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-08-06  4:00 Mark C Favas - SysAd [this message]
1996-08-07  4:00 ` DEC C compiler bug - Digital Unix 4.0 John Kohl
1996-08-12  4:00   ` Daniel Lewis
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox