- From: Wyss, Felix <FelixW@inin.com>
- Date: Thu, 31 Jul 2003 08:11:43 -0500
- To: "Serge LE HUITOUZE" <slehuitouze@telisma.com>, <www-voice@w3.org>
> > An alternate workaround would be the following:
> >
> > $command1 = (set | turn)
> > $object
> > $state
> > {$.o=$object; $.s=$state};
> >
> > private $object = $<http://www.example.com/object>;
>
> This would not work as is: The semantics would be lost (see paragraph
> 5, Default Assignment, in SISR 2003 WD).
> The private rule should be written:
> private $object = $<http://www.example.com/object> {$=$$};
>
D'oh! You are of course right. I should have written it as:
private $object = $<http://www.example.com/object> {$=$$};
Thinking about this a bit more, there would be a way to solve this more generically. The external rule reference production of SRGS could be extended as follows:
ExternalRuleRef ::=
'$' (ABNF_URI | '$' ABNF_URI_with_Media_Type) '^<' GRRAttribute '>'
A corresponding attribute would have to be specified for the <ruleref> element of the XML representation.
Your example could now be written as:
$command1 = (set | turn)
$<http://www.example.com/object>^<$object>
$state
{$.o=$object;$.s=$state};
Technically, this really isn't much different from assigning the GRR to a temporary variable right after the external reference. It thus may not be worth the change to the SRGS specification.
--Felix
Received on Thursday, 31 July 2003 09:12:01 UTC