conformance constraints on producers that go beyond syntax

This sentence from http://www.whatwg.org/specs/web-apps/current-work/
is really pretty thought-provoking...

"Authors must not use elements, attributes, and attribute values for
purposes other than their appropriate intended semantic purpose."

This bears on our language versioning discussion, because it reminds
us that conformance requirements for producers may go beyond just the
requirement that what they produce be syntactically well-formed; they
can say that based on its circumstances, the producer MUST choose
certain syntactically correct texts over others. You don't often see
this kind of thing in language specs, although it is very easy to
imagine in specs for larger systems of which a language is a part
(such as: if the heart rate button is depressed then the generated
document MUST contain a <heartrate> element that correctly records the
measured heart rate).

"Use the word 'red' to describe red balls and 'green' to describe
green balls" would be a similar sort of producer constraint, as would
"don't issue commands that would fill up the file system" or even "do
not lie". Some "good practice notes" fall in a similar category.

This kind of producer constraint is natural if you think of consumer
and producer as symmetrical: the consumer observes something in the
world (perhaps including its own internal state) and creates a
document "expressing" something, maybe a desire, in response; the
consumer then reads the document and does something that makes the
world (perhaps its own internal state) react.  world -> document ->
world. (This is the language-game framework I've been trying to get
you all interested in.) But we rarely see this because language specs
usually assume that the producer's motives for generating a document
are its own g**n business and that it will figure out what document it
needs to generate based on what it wants consumers to do / understand.
Producer mistakes are self-correcting - the consumer doesn't do what's
wanted - so correct expression of desire doesn't have to be mandated.

(On an unrelated point - is the above requirement part of HTML4? I'm
pretty sure it's not generally obeyed in the wild. If not, doesn't
this constitute a seriously incompatible change from HTML4 to HTML5,
creating a population of HTML4-conforming producers that are not
HTML5-conforming producers?)

-Jonathan  (just having some fun)

Received on Saturday, 19 September 2009 00:18:26 UTC