The hold[]
directive helps managing attributes, mainly for alternative parsers.
It instantiates a new attribute instance for the embedded parser. The
value of that attribute instance is copied to the outer attribute if
the embedded parser succeeds and it is discarded otherwise. Alternative
parsers normally do not rollback changes made to the outer attribute
by an failed alternative. Wrapping those alternatives into a hold[]
directive ensures that only the succeeding alternative gets to modify
the attribute.

The hold[]
directive uses swap() to implement the rollback/commit
semantics for the attribute. For this reason the attribute type needs
to to be usable with boost::swap
(needs to either define a proper overload for swap(attribute_type&,attribute_type&) or expose a member function
attribute_type::swap(attribute_type&).