Making sure that SGML is parsed

This hack simply makes sure that SGML tags are parsed. Currently we are
not interested in parsing SGML but definitely need the ability to parse
and load XML files with these tags.

SGML tags are <!--, <!DOCTYPE  and <![CDATA[...
BUGFIX: Continuing loading after SGML tag

If there is an SGML tag in the top level like <!DOCTYPE ... then the
load-object returns with the SGML object. This is not desirable.

This commit changes this behavior such that entire file is parsed and
the last valid (nonSGML) object is returned.