[Date Prev][Date Next][Thread Prev][Thread Next][Author Index][Date Index][Thread Index]

Re: ORDER_BOMB / EXPORT_BOMB status?



> Inspection of the code for these in bombx.hxx seems to be right,
> however the comments indicate that its an only-future-tense feature.
> With anyone else (including myself), I'd just assume the comments were
> out of date, but in this case I thought I'd better check. []
> 
> If ORDER_BOMB & EXPORT_BOMB now work, I think we should consider
> DESIGN_BOMB to be obsolete (but left in for now).

Though they are not tested explicitly, ORDER_BOMB(), BUILD_BOMB(), and
code equivalent to EXPORT_BOMB() are used internally by bombx.cxx for
the guts of SHIELDS.  So they are tested implicitly, which means they
now work.

I also noticed that the comments were out of date in DESIGN_BOMB.  They
talked about knowlege about ORDER_BOMB that those macros no longer use.

> Btw, "static class ...." doesn't mean anything in ARM C++.  I don't
> know that it ever meant anything in any C++.  (Yes, I know what it
> should mean, but I didn't design it)

What do YOU think it should mean?  (If it means one of the two things
I suspect it should mean, it better work, or it breaks

	"static class Foo {...} fooInstance;"

and probably "static struct..." as well.  If it means the other, and
it doesn't work, there's the possibility that bombs will have a global
name space on some platforms.)

I noticed that the macros SHIELD_RETURN(), SHIELD_VOID, SHIELD_BREAK,
and SHIELD_CONTINUE aren't in the alpha-6 version.  I'll add them to
my new version for the merge.

These little gems are for use inside shields, to shut up the bogus
"statement not reached" warning.  To use them, substitute:

	SHIELD_BREAK;			for	break;
	SHIELD_CONTINUE;		for	continue;
	SHIELD_RETURN(retval);		for	return retval;
	SHIELD_RETURN(SHIELD_VOID);	for	return;

		michael