[DFDL-WG] Issue 163: Expressions returning ES - type of error when expression returns wrong type.

Mike Beckerle mbeckerle.dfdl at gmail.com
Tue Jan 24 09:15:24 EST 2012


Also, we're trying to reserve expressions that have multiple-returns (aka
sequences of more than one value) for potential future use. E.g., should we
ever want to add array-valued expressions in the future - a not unlikely
extension. So we definitely don't want them "sliding into" use
inadvertently.

...mikeb

On Tue, Jan 24, 2012 at 4:25 AM, Steve Hanson <smh at uk.ibm.com> wrote:

> Tim and I have discussed this and we are ok with making these situations
> schema definition errors rather than processing errors. We've not been able
> to find a realistic use case where an expression failing in this manner
> could legitimately be interpreted as failing to discriminate a point of
> uncertainty. It almost certainly indicates a problem withe the expression
> or an ambiguity with the model.  For example, in the sequence case, the
> modeler can always return a single element by using a predicate in the
> expression (eg {../count[1]} )
>
> Regards
>
> Steve Hanson
> Architect, Data Format Description Language (DFDL)
> Co-Chair, *OGF DFDL Working Group* <http://www.ogf.org/dfdl/>
> IBM SWG, Hursley, UK*
> **smh at uk.ibm.com* <smh at uk.ibm.com>
> tel:+44-1962-815848
>
>
>
> From:        Mike Beckerle <mbeckerle.dfdl at gmail.com>
> To:        dfdl-wg at ogf.org
> Date:        19/01/2012 01:33
> Subject:        [DFDL-WG] Issue 163: Expressions returning ES - type of
> error when expression returns wrong type.
> Sent by:        dfdl-wg-bounces at ogf.org
> ------------------------------
>
>
>
> I reviewed section 23. The last paragraph of 23.3 is inconsistent with the
> rest of the section.
>
> Suggested revised wording:
>
> The result of evaluating the expression must be a single atomic value of
> the type expected by the context, and it is a schema definition error
> otherwise. Some XPath expressions naturally return a sequence of values,
> and in this case it is also schema definition error if an expression
> returns a sequence containing more than one item. If the expression returns
> an empty sequence it will be treated as returning *nil*.
>
>
> --
> Mike Beckerle | OGF DFDL WG Co-Chair
> Tel:  *781-330-0412* <781-330-0412>
> --
>  dfdl-wg mailing list
>  dfdl-wg at ogf.org
>  https://www.ogf.org/mailman/listinfo/dfdl-wg
>
>
>
>  ------------------------------
>
> *
> *
>
> *Unless stated otherwise above:
> IBM United Kingdom Limited - Registered in England and Wales with number
> 741598.
> Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU
> *
>
>
>
>
>
>
>


-- 
Mike Beckerle | OGF DFDL WG Co-Chair
Tel:  781-330-0412
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.ogf.org/pipermail/dfdl-wg/attachments/20120124/c173d259/attachment.html>


More information about the dfdl-wg mailing list