[cfe-commits] r82293 - in /cfe/trunk: include/clang/Sema/CodeCompleteConsumer.h lib/Sema/CodeCompleteConsumer.cpp test/CodeCompletion/functions.cpp

Douglas Gregor dgregor at apple.com
Mon Sep 21 14:33:38 PDT 2009


On Sep 21, 2009, at 2:12 PM, Chris Lattner wrote:

>
> On Sep 18, 2009, at 3:15 PM, Douglas Gregor wrote:
>
>> Author: dgregor
>> Date: Fri Sep 18 17:15:54 2009
>> New Revision: 82293
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=82293&view=rev
>> Log:
>> Introduce code completion strings, which describe how to *use* the
>> results of code completion, e.g., by providing function call syntax
>> with placeholders for each of the parameters.
>
> Very nice Doug,
>
> Would it make sense to support "informational" Chunks which would be  
> shown in the list of possibilities the user would select from, but  
> would not be inserted?  This would allow you to say that "Base::N"  
> is hidden in a base class, but "N" is in "class foo".
>
> In fact, when completing P->  for members that are not in P's direct  
> class (but are in base classes) it would be nifty to show which base  
> class they come from in the popup.  What do you think?


I like it. We currently provide qualification when the name in the  
base class (or an outer context) is *hidden*, because in that case we  
show the qualification is needed for us to have any chance of doing  
the right thing.

One concern about showing the qualification like "Base::" for all  
members found in base classes is that it could take up a lot of  
horizontal space, especially for people who like long class names :)

	- Doug



More information about the cfe-commits mailing list