On Tue, 15 Jul 2003 22:22:03 +0200, Peter Dimov wrote:
> Daniel Frey wrote:
>>
>> To explain the bug a bit: When you create a small test case, you'll
>> probably get the error from the compiler you are looking for. If you
>> put
>> the checked_delete in it's own header, it still works as long as you
>> include the header with
>>
>> #include "my_header.h"
>>
>> but if you use
>>
>> #include
>>
>> and compile it with -I. then the compiler magically accepts
>> sizeof(Incomplete) with no warnings or errors and returns 0 as the
>> size.
>
> Looks like a "feature" to me. Apparently some important system header
> does sizeof(incomplete).
"It's not a bug, it a feature!" (tm) ;)
I know they will find a convincing excuse, but that doesn't help us as we
create a library which is usually used through <> instead of "".
>> To work around this, I added a simple STATIC_ASSERT which - for some
>> reason - still works :)
>
> Odd, since the Intel-specific BOOST_STATIC_ASSERT is
>
> [snip]
>
> which looks pretty close to what checked_delete uses.
That's correct. I don't know why it works in one case but not in the
other. But we've seen stranger bugs already, haven't we? :))
>> +#include
>> +#if defined(BOOST_INTEL)
>> +#include
>> +#endif
>
> Dependencies. I hate dependencies.
Do you have a better idea?
Regards, Daniel
___
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost