conflicting answers

Scott Cooper scott at iguana.co.nz
Wed Nov 5 21:06:05 GMT 1997


thanks for all the responses - sorry to chris for any 'railing' but i was
having an extra annoying day.

just to summarize:

tim says:
Recent WG decisions require that parameter entity expansions (outside
of entitity values) should be forced to match an even number tokens
simply by appending & prepending spaces to their expansion; I 
hypothesize that this is what the msxml code is doing.

chris maden says:
That's absolutely uncool.  My résumé is NOT a r é sum é .
This will, I hope, be fixed before the actual release.

andrew says:
Yes, the MSXML code is attempting to match the XML specs as recently revised
by the WG decision.  (Thanks for the test files, Tim, Henry and Michael:
We'll use these in testing.)

chris says:
The code;
	 if (sb.length() > 0)
       	sb.append(' ');
is a bug and will be removed from next version, along with several other
things :-)


so could someone please explain the WG decision and hasn't chris maden got
a pretty good point?


chris (lovett): i wanted to use CDATA in an entity definition 'cos i might
stick a lot of crazy characters in there - like some apostrophes for
instance - but reading tim's test files i see it's common to escape tricky
characters with their hex equivalents - it's just a pain if you've got a
large entity definition. am i using entities incorrectly? - i think of them
as macros and i expect them to be expanded as normal text and then the
expanded text parsed so sticking a CDATA in there shouldn't really matter.

finally (msxml question): in my dtd i want to use entities to set attribute
defaults...
<!ENTITY % foo 'abc'>
<!ENTITY % bar '"def"'>
<!ELEMENT baz EMPTY>
<!ATTLIST baz
	arg1 CDATA '%foo;'
	arg2 CDATA %bar;>
under msxml, arg1 gets a default of '%foo;' and arg2 gets a default of
'def', suggesting parameter entity references aren't expanded within the
default string in an attdef(?). good, bad and/or ugly? 
it means tim's entval2.xml has this line in it's expansion under msxml:
BAR CDATA "A{Value of b}C%d;EMF"

thanks heaps for those test files - i was trying every which way of getting
the defaults to expand properly within the dtd - and now i can!
---------------------------------------------------------------------
Iguana Information Services 		Ph    +64 4 499 9782
PO Box 10 609				Fax   +64 4 499 4439
Wellington				Email scott at iguana.co.nz
New Zealand				HTTP  http://www.iguana.co.nz

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev at ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To (un)subscribe, mailto:majordomo at ic.ac.uk the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo at ic.ac.uk the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa at ic.ac.uk)




More information about the Xml-dev mailing list