Re: Error definition

> I think that any parser is necessarily also a "recogniser"

Yes, but not vice versa (I think?). So that was my point - if what we have is *only* a recognizer, all it has to do is say yes or no, and either answer may be equally interesting. But if it’s a parser, it needs to parse. In the case of ixml, if it can’t recognize it can’t parse, so it fails.

> I suppose there may also be errors that are due to reasons other than the input not being a sentence in the grammar: we really ought to think about having some standard error codes.

One that springs to mind is a badly-formed grammar.

BTW
___________________________________________________ 
Dr. Bethan Tovey-Walsh 
Myfyrwraig PhD | PhD Student CorCenCC 
Prifysgol Abertawe | Swansea University 
Croeso i chi ysgrifennu ataf yn y Gymraeg.

> On 4 Feb 2022, at 12:13, Tom Hillman <tom@expertml.com> wrote:
> 
> I don't think you are wrong, although I think that any parser is necessarily also a "recogniser": to "recognise" a piece of text, all you can really do is try to parse it and see if it succeeds...
> 
> I suppose there may also be errors that are due to reasons other than the input not being a sentence in the grammar: we really ought to think about having some standard error codes.
> 
> _________________
> Tomos Hillman
> eXpertML Ltd
> +44 7793 242058
> On 4 Feb 2022, 12:00 +0000, Bethan Tovey-Walsh <accounts@bethan.wales>, wrote:
>> I’m inclined to agree with Dave. I wouldn’t call it an error if the implementation were only a recogniser: it would make sense in that context for the outcomes “yes, this is a sentence” and “no, this is not a sentence” to be of (potentially) equal interest and value. But the point of the ixml parser is to provide vxml output, not to tell you whether your input string is a valid sentence or not. If it can’t provide that output, I’d call that an error.
>> 
>> Happy to hear why I’m wrong, though; my instinctive understanding is sometimes way off base.
>> 
>> Sent from my iPhone
>> 
>>> On 4 Feb 2022, at 09:36, Dave Pawson <dave.pawson@gmail.com> wrote:
>>> 
>>> O Regan, Gonorill, your old kind father
>>> Whose franke heart gaue you all, O that way madnes lies,
>>> Let me shun that, no more of that.
>>> -Bill S
>>> 
>>> When I compile a programming language program,
>>> I may get warnings, but (to me) the compile either
>>> succeeds or fails.
>>> 
>>> I would hope that with an ixml grammar and input string
>>> I can rely on the same reasoning? Pass / fail (or pass,
>>> with warnings). From this I expect my vxml output to
>>> be complete, no 'missing bits'?
>>> 
>>> I'm using a Saxon class implementation, so if it has a bug
>>> I can look for a blue moon.
>>> 
>>> Is this assumption reasonable / agreed?
>>> 
>>> 
>>> 
>>> regards
>>> 
>>> 
>>> 
>>> 
>>> --
>>> Dave Pawson
>>> XSLT XSL-FO FAQ.
>>> Docbook FAQ.
>>> 
>> 
>> 

Received on Friday, 4 February 2022 12:30:57 UTC