HP-UX cc does not like automatic array initializers
Closed / Fixed218686ffffffffffffffffffffffffffffffffffCreated 26 years agoUpdated 26 years ago
Descriptionplain2000-10-26 01:04:07
OriginalBugID: 1736 Bug
Version: 8.1b2
SubmitDate: '1999-04-06'
LastModified: '1999-04-06'
Severity: CRIT
Status: Released
Submitter: pat
ChangedBy: pat
OS: HP-UX
OSVersion: 10.20
Machine: Other
FixedDate: '1999-04-06'
ClosedDate: '2000-10-25'
Name:
Joe Kelsey
ReproducibleScript:
cd unix# HP-UX 10.20, HP ANSI C compiler
CC="cc -Ae" ./configure
make
ObservedBehavior:
cc -Ae -c -O -I./../generic -I. -DHAVE_GETCWD=1 -DNO_DLFCN_H=1
-DHAVE_UNISTD_H=1 -DUSE_TERMIOS=1 -DHAVE_SYS_TIME_H=1
-DTIME_WITH_SYS_TIME=1 -DHAVE_TZNAME=1 -DHAVE_TIMEZONE_VAR=1
-DHAVE_ST_BLKSIZE=1 -DSTDC_HEADERS=1 -DNO_UNION_WAIT=1 -DNEED_MATHERR=1
-DRETSIGTYPE=void -DHAVE_SIGNED_CHAR=1 -DHAVE_SYS_IOCTL_H=1
-DTCL_SHLIB_EXT=\".sl\" ./../generic/tclCmdIL.c
cc: "../generic/tclCmdIL.c", line 2815: error 1521: Incorrect
initialization.
cc: "../generic/tclCmdIL.c", line 2815: error 1521: Incorrect
initialization.
*** Error exit code 1
DesiredBehavior:
tclCmdIL.c, line 2815:
Tcl_Obj **objv, *paramObjv[2] = {objPtr1, objPtr2};
This is a violation of ANSI C 3.5.7, initialization of a variable of
static
storage duration with an invalid constant. HP C does not allow this. The
initialization must occur in run-time code, e.g.,
paramObjv[0] = objPtr1; paramObjv[1] = objPtr2;
04/06/1999 14:33 - pat -fixed per Scott Redman. The fix will be in Tcl 8.1b3.
welch Closed ticket [218686ffff].
[History diff]2000-10-26 08:27:11
Log in (anonymous is fine) to add a comment.