[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]
Re: [xml-dev] ID/IDREF is evil
- From: Steve Newcomb <srn@coolheads.com>
- To: xml-dev@lists.xml.org
- Date: Mon, 03 Feb 2014 21:34:07 -0500
Roger,
How, exactly, does your proposed additional constraint actually
facilitate communication?
Or perhaps you believe XML has some purpose other than communication?
You recommend taking a cue from the lore of compiler construction.
But compilers are not focused on communication; their only purpose is to
*facilitate control over processes*. Do you really feel that XML's
primary purpose is to facilitate control over processes? I'm finding it
hard to believe that that's what you really think.
You seem to be saying that, whatever the purpose of XML might be, the
exploitation of some of its features necessarily impedes progress toward
the fulfillment of that purpose. In order to convince me of your point,
you must articulate the purpose you think XML is supposed to fulfill.
Right now, I'm finding your point comparable to a claim that human
beings should abandon rice in favor of Rice Krispies in order to avoid
consuming the energy required to boil real rice.
Steve
On 02/03/2014 05:05 PM, Costello, Roger L. wrote:
> All known parsing algorithms for context-sensitive
> grammars are either very inefficient or very complex.
>
> Reasoning about context-sensitive grammars is difficult.
>
> Proofs about context-sensitive grammars is difficult.
>
> Take cue from compiler developers: they separate
> context-sensitive processing into a separate pass.
>
> So don't use ID/IDREF.
>
> Of course, that doesn't mean you will never have data that has intra-data dependencies. What it means is that you should modularize your grammar rules: express your context-free rules in your XML document and express your context-sensitive rules (intra-data dependencies) in Schematron. That's a nice, clean separation-of-concerns. That's a modular data design.
>
> Let's recap:
>
> 1. ID/IDREF introduces context-sensitive rules into your XML grammar wherever there is an ID attribute and wherever there is an IDREF attribute.
>
> 2. Don't use ID/IDREF.
>
> 3. Modularize your rules: express context-free rules in XML and express context-sensitive rules in Schematron.
[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]