Hrrmmm shouldn't those lines be...
rirving at onecall.net
Fri Sep 8 20:04:05 UTC 2000
Don Lewis wrote:
> On Sep 7, 6:44pm, Russ Allbery wrote:
> } Subject: Re: Hrrmmm shouldn't those lines be...
> } > Now, I can memcpy ( array, target, size), or, I can memcpy (
> } > &array, target, size ).
> } > According to my tired old K&R background, number 2 is wrong..
> } > err...sloppy, in C.
> } They're defined by the standard as being entirely equivalent in this
> } context, and I'm pretty sure that even K&R would have treated them as
> } such.
> I don't think &array was legal K&R. I just tried compiling it with
> the SunOS bundled cc, and it whined:
> "std.c", line 5: warning: & before array or function: ignored
> There are also some differences between &array and array:
> sizeof(*(&array)) == sizeof(array)
> sizeof(*array) == sizeof(array)
> array != (&array)
Yup. And IMO, using that ISO standard, of the & returning an
and since another ISO standard defines "array" as returning the
base lvalue of the array,
&array -should- be the address of the address of the array.
Not the address of the array... But, again, only IMHO.
Reminds me of an assembler instruction. :)
I linted the innd module, BTW,
- YEESH -
Somebody cutting a check for this ?
More information about the inn-workers