attributes() should return namespace declarations.
Merge pull request #2253 from TomByrne/development

attributes() should return namespace declarations.