Re: [PATCH 3/4] spellcheck.h: add best_match template; implement early-reject

2016-06-14 Thread Jeff Law
On 06/14/2016 09:15 AM, David Malcolm wrote: There's a lot of repetition between find_closest_string and find_closest_identifier, and the next patch adds more, so this patch moves the logic into a new template class "best_match" for locating the closest string from a sequence of candidates. The

[PATCH 3/4] spellcheck.h: add best_match template; implement early-reject

2016-06-14 Thread David Malcolm
There's a lot of repetition between find_closest_string and find_closest_identifier, and the next patch adds more, so this patch moves the logic into a new template class "best_match" for locating the closest string from a sequence of candidates. The patch also introduces a pair of early-reject op