Skip to main content

Opinion on COMMENTS (but not comments on opinions)

No replies
Joined: 2004-11-18


I'm working on converting a particular file format (called Touchstone in case you're wondering) to XML. I've written a parser & dtd and have validated and everything is cool so far.

I'm wondering is there is a best way to handle annotations that occur within a data file. Most data file formats have some sort of annotation mechanism like "//" "/* */" ";" "!" or whatever;

// a comment
/* also a comment */
# this is a neat one
; ditto
! touchstone comment marker here

Should a person designing an XML document based on a file format try to convert these to
or create an element called
a comment?

I'm reading about XML schemas now and perhaps I might need to make this an . Who knows?

Any opinions?