Peter Kenny wrote > I would expect the parser which fails to also > fail, for the same reason, if the input is just 'John Smith' without the > 'Jr'.
Correct! It did. Peter Kenny wrote > The top-level construct in your parser is PPSequenceParser, which works in > a > simple-minded way; it just checks whether each of its component parsers > succeeds. If one of them fails, the whole sequence fails; it does not try > backtracking. Ah, okay. That makes sense. It seems I just got lucky in that when I've done this before, it was the special case you mention below of unique tokens Peter Kenny wrote > firstName, ((middleName, lastName)/ lastName), generational optional That worked for all interesting cases. Peter Kenny wrote > If you are going to produce a parser which copes with all the vagaries of > people's names, especially outside the US, I think you will have some fun. Ha ha, no doubt. I am not presuming to capture the whole domain, just an interesting - and thankfully very limited - subset! Thanks for all the help :) ----- Cheers, Sean -- Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html