Developer forums (C::B DEVELOPMENT STRICTLY!) > CodeCompletion redesign
new cc search implemention
blueshake:
hi,all
after a week's work,I finally finish this patch.it is the most complicated patch I had made.
as we know,the current cc use FindAIMatch function to get the matched tokens.people complain its low efficiency.
that is true because it use recursive calls.and I found it is hard to understand ,not mention to maintain it.at least for me,it is so.
so I rewrite FindAIMatch function.of course ,I abandon recursive calls.
I am not going to explain the whole search process, just started from what I changed.
1.first I use GenerateResultSet to get the tokens from search scope set.it is the same story as before.but a little different here.
I directly get the matched search text from the tree and then eliminate those which are not under the search scope set.
2.ResolveAutualType
this function is used to resolve the function/variable's actual type.
3.ResolveExpression
just the name said,it is used to resolve the expression. it is used to replace the FindAIMatch function.
if you want to ask what is the biggest different?
here is the answer.try the complained thing.you can see how fast it is. :lol:
--- Code: ---string::append.append.append.append.append.append.
--- End code ---
patch for it.
oBFusCATed:
There is a typo? ResolveAutualType , should be ResolveActualType maybe?
blueshake:
--- Quote from: oBFusCATed on February 28, 2010, 12:05:59 pm ---There is a typo? ResolveAutualType , should be ResolveActualType maybe?
--- End quote ---
you are right. :D :D :D
ollydbg:
I have just applied in my local copy, and it works quite well.
blueshake:
Another update.
-make the search work fine for "this" now.
-better handle for operator overload(show or not)
e.g.
class::----------here we may want to show operator overload.
variable.--------here we do not want to show.
[attachment deleted by admin]
Navigation
[0] Message Index
[#] Next page
Go to full version