U++ framework
Do not panic. Ask here before giving up.

Home » U++ Library support » U++ Core » String should implement the Boyer Moore algo
Re: String should implement the Boyer Moore algo [message #42220 is a reply to message #42198] Fri, 28 February 2014 11:50 Go to previous messageGo to previous message
mirek is currently offline  mirek
Messages: 14291
Registered: November 2005
Ultimate Member
Thing is, Find is meant for searching in relatively small Strings. IMO, in that case, the cost of precreating search tables in B-M algo outweights any possible gains. It also seams to me that for the same reason, such utility, which would definitely be useful in some cases, should be rather implemented as "search class" - because you can then "compile" the pattern once, then use for searching several times.

So for String::Find, let us consider the "brute force" a feature.

I would be nice to have BM as separate thing (class probably).

But another thing is that perhaps full PCRE has similar characteristics to BM but much more flexible use... (but I might be wrong about this one...)

Mirek
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Bug: AString<B>::ReverseFind broken for wchar
Next Topic: AMap's FindAdd, FindPut API changed
Goto Forum:
  


Current Time: Fri May 15 22:56:26 GMT+2 2026

Total time taken to generate the page: 0.00588 seconds