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

Re: is it wise to provide hooks to customize ExceptionalUnitGraph'sconstructors?



On Mon, 22 Mar 2004, John Jorgensen wrote:

> I'm not clear on what you mean by a class invariant.  Wouldn't
> the properties that must hold for every instance of a CFG
> class include things like "if a node is a conditional branch, its
> successors will include the node it falls through to and the node
> it branches to"?  Or are you referring to some narrower
> structural properties, like "the set of all successors of a node
> must equal the union of the sets of its exceptional and
> unexceptional succeesors)?

Usually these properties tend to be easiest to show on an empty CFG.  So
if your constructor just makes an empty CFG, which is to be populated
later, then your class invariant gets trivially satisfied.

pat