Mailing List Archive

Compile errs
Trying to install on an old ncr_tower running AT&T SysV R2, I get the
following compile errors. I've included cuts of the programs after each
error. Got any suggestions on hot to eliminate the errors? Are they
anything to worry about?

`sh cflags libperl.a toke.o` toke.c
CCCMD = cc -c -W2,-Sl,1500 -W0,-Sp,350,-Ss,2500 -Wp,-Sd,30 -O0
"toke.c", line 1037: warning: illegal pointer combination, op ==

1033 warn("filter_del func %lx", funcp);
1034 if (!rsfp_filters || AvFILL(rsfp_filters)<0)
1035 return;
1036 /* if filter is on top of stack (usual case) just pop it off */
1037 if (IoDIRP(FILTER_DATA(0)) == (void*)funcp){
1038 /* sv_free(av_pop(rsfp_filters)); */
1039 sv_free(av_shift(rsfp_filters));
1040
1041 return;
1042 }


`sh cflags libperl.a gv.o` gv.c
CCCMD = cc -c -W2,-Sl,1500 -W0,-Sp,350,-Ss,2500 -Wp,-Sd,30 -O0
"gv.c", line 967: warning: ambiguous assignment: simple assign, unary op
assumed

963 && (cv = cvp[off=method])) { /* Method for right
964 * argument found */
965 lr=1;
966 } else if (((ocvp && oamtp->fallback > AMGfallNEVER
967 && (cvp=ocvp) && (lr=-1))
968 || (cvp && amtp->fallback > AMGfallNEVER && (lr=1)))
969 && !(flags & AMGf_unary)) {
970 /* We look for substitution for
971 * comparison operations and
972 * concatendation */
Re: Compile errs [ In reply to ]
UNIXdoug@aol.com writes:
>
> Trying to install on an old ncr_tower running AT&T SysV R2, I get the
> following compile errors. I've included cuts of the programs after each
> error. Got any suggestions on hot to eliminate the errors? Are they
> anything to worry about?
>

I wrote the second, but where are the errors?

I see warnings only. Anyway, the probability you go this particular
branch is quite low ;-) I think it is not covered by overload.t.

Ilya

> `sh cflags libperl.a toke.o` toke.c
> CCCMD = cc -c -W2,-Sl,1500 -W0,-Sp,350,-Ss,2500 -Wp,-Sd,30 -O0
> "toke.c", line 1037: warning: illegal pointer combination, op ==
>
> 1033 warn("filter_del func %lx", funcp);
> 1034 if (!rsfp_filters || AvFILL(rsfp_filters)<0)
> 1035 return;
> 1036 /* if filter is on top of stack (usual case) just pop it off */
> 1037 if (IoDIRP(FILTER_DATA(0)) == (void*)funcp){
> 1038 /* sv_free(av_pop(rsfp_filters)); */
> 1039 sv_free(av_shift(rsfp_filters));
> 1040
> 1041 return;
> 1042 }
>
>
> `sh cflags libperl.a gv.o` gv.c
> CCCMD = cc -c -W2,-Sl,1500 -W0,-Sp,350,-Ss,2500 -Wp,-Sd,30 -O0
> "gv.c", line 967: warning: ambiguous assignment: simple assign, unary op
> assumed
>
> 963 && (cv = cvp[off=method])) { /* Method for right
> 964 * argument found */
> 965 lr=1;
> 966 } else if (((ocvp && oamtp->fallback > AMGfallNEVER
> 967 && (cvp=ocvp) && (lr=-1))
> 968 || (cvp && amtp->fallback > AMGfallNEVER && (lr=1)))
> 969 && !(flags & AMGf_unary)) {
> 970 /* We look for substitution for
> 971 * comparison operations and
> 972 * concatendation */
>
Re: Compile errs [ In reply to ]
On Fri, 25 Aug 1995 UNIXdoug@aol.com wrote:

> Trying to install on an old ncr_tower running AT&T SysV R2, I get the
> following compile errors. I've included cuts of the programs after each
> error. Got any suggestions on hot to eliminate the errors? Are they
> anything to worry about?
>
> `sh cflags libperl.a toke.o` toke.c
> CCCMD = cc -c -W2,-Sl,1500 -W0,-Sp,350,-Ss,2500 -Wp,-Sd,30 -O0
> "toke.c", line 1037: warning: illegal pointer combination, op ==
>
> 1033 warn("filter_del func %lx", funcp);
> 1034 if (!rsfp_filters || AvFILL(rsfp_filters)<0)
> 1035 return;
> 1036 /* if filter is on top of stack (usual case) just pop it off */
> 1037 if (IoDIRP(FILTER_DATA(0)) == (void*)funcp){

This is just a missing cast. I see this message too. Once I get my
system back up, I can probably expand all the macros and figure out the
missing cast. (IoDIRP is probably not (void *)).

Anyway, this is probably harmless. SysV.[123] compilers tended to be
quite alarmist about such statements without casts.

> `sh cflags libperl.a gv.o` gv.c
> CCCMD = cc -c -W2,-Sl,1500 -W0,-Sp,350,-Ss,2500 -Wp,-Sd,30 -O0
> "gv.c", line 967: warning: ambiguous assignment: simple assign, unary op
> assumed

> 967 && (cvp=ocvp) && (lr=-1))

That's just the old -= vs. =- vs. = - ambiguity. (Remember, this is
SysVr2, an old system that was built to deal with a lot of old System III
and v7 code.) Rewriting it as
&& (cvp=ocvp) && (lr = -1))
should make the compiler happier. (Doesn't VMS have this problem
too?)

Hope this helps someone,

Andy Dougherty doughera@lafcol.lafayette.edu
Dept. of Physics
Lafayette College, Easton PA 18042