]> granicus.if.org Git - clang/commit
Don't walk the translation unit context to produce protocol names when
authorDouglas Gregor <dgregor@apple.com>
Thu, 9 Dec 2010 21:44:02 +0000 (21:44 +0000)
committerDouglas Gregor <dgregor@apple.com>
Thu, 9 Dec 2010 21:44:02 +0000 (21:44 +0000)
commit70c233591ad2f77a01c8a318283ae03010c64c8f
treec61a9c5a70cfa448f3bf24a9b86ca151526e56d6
parentd64f4c14029f970caafb0bdfcf07f9fecfe5c68b
Don't walk the translation unit context to produce protocol names when
global code completions are disabled (e.g., because they are
cached). Also, make sure that forward-declared protocols are visited
when we look for all visible names within a declaration context.

Previously, we would end up with duplicate completions for protocols.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@121416 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Sema/SemaCodeComplete.cpp
lib/Sema/SemaLookup.cpp
test/Index/complete-protocols.m