On Fri, Feb 18, 2005 at 08:12:30AM -0800, Linus Torvalds wrote:
> 
> 
> On Fri, 18 Feb 2005, Christopher Li wrote:
> 
> Yeah, I should just allow that internally, and then just have a flag that 
> enables the warning for kernel code. Sparse internally already has some 
> support for a dynamic "array_size" (it _is_ a "struct expression *"), but 
> to actually do the right thing is not trivial.

I agree, even if you copy the expression, now sizeof becomes an
expression instead of constant value. Any thought of handling the
type size in bit_size then?

I am thinking of insert an internal symbol for the new sizeof
expression, at the place where size of array get evaluated.
Then all the later sizeof reference will be come using that
symbol.

Chris

-
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to