Ok!
Maybe, I should write some pseudocode:
void foo(Element_t *p){
int_t array_len = 0;
array_len = sizeof(p)/sizeof(Element_t);
}
2009/4/10 Paul Herring <[email protected]>
>
>
> On Fri, Apr 10, 2009 at 4:06 AM, Nicle <[email protected]<ynicle%40gmail.com>>
> wrote:
> > I pointed out the 32bits system that was just for "sizeof(p)", not for
> > "sizeof(char)".
>
> You're missing my point. sizeof(char) is always redundant.
>
> > Under 32bits system, always "4", cause: 4/1=4.
>
> And anyway, where CHAR_BIT is 32, it's not inconceivable that your
> code snippet would return 1, not 4.
>
> --
> PJH
>
> http://shabbleland.myminicity.com
> http://www.chavgangs.com/register.php?referer=9375
>
>
[Non-text portions of this message have been removed]