Can't m_kind be coded somewhere else? If m_name is invalid, its bits can be used to distinguish the node types that doesn't have names, and for elements, attributes and processing instructions, we need two bits, somewhere. Attributes and processing instructions can't have a size, is that of help? There's also certain rules for the names. For instance, a processing instruction will never have a prefix nor namespace. Neither will an attribute node have a default, non-empty namespace, right?