rankByTokenCountobjectparser.t[6037]

Rank by token count. Other things being equal, we'd rather pick a longer match. If one match is shorter than the other in terms of the number of tokens it encompasses, then it means that the shorter match left more tokens at the end of the command to be interpreted as separate commands. If we have an interpretation that can take more of those tokens and parse them as part of the current command, that interpretation is probably better.

rankByTokenCount :   CommandRankingCriterion

Superclass Tree   (in declaration order)

rankByTokenCount
        CommandRankingCriterion
                object

Summary of Properties  

(none)

Summary of Methods  

comparePass1 

Inherited from CommandRankingCriterion :
comparePass2 

Properties  

(none)

Methods  

comparePass1 (a, b)OVERRIDDENparser.t[6039]

first pass - compare token counts

TADS 3 Library Manual
Generated on 5/16/2013 from TADS version 3.1.3