Re: SCXML Test 354 uses datamodel-specific <content>?

Le 30 jun 2014 à 15:53, Jim Barnett <1jhbarnett@gmail.com> a écrit :

> What would happen in test 179, where we have conf:eventDataVal="123"?  Would it be a problem to quote that in ECMA?

Not at all. A number is equivalent (==) to its string representation in ECMAScript.


As for foo, it needs to be quoted in the cond expression as Stefan said. It a string semantically. According to the spec the <content>foo</content> must always be parsed as a string, not because it has quotes but because it fails to parse as JSON or XML and so the interpreter must fall back to string without trying anything else.

I see two ways out of this. If it seems like a good idea to have JSON parsing by default in any datamodel and no platform-specific format, then Gavin should implement the spec, with or without JSON (which is optional).
Otherwise, move some of the requirements currently in B.2.8.1 to the ECMAScript section, so that platforms for which JSON is not an obvious choice are free to define their own default format and heuristics for writing structured data inline. In which case the test becomes optional and Gavin doesn't need to pass it since he doesn't support the ECMASCript datamodel.

			David

Received on Monday, 30 June 2014 14:29:00 UTC