ide: Assist: Fixed issue with global namespace #1413

git-svn-id: svn://ultimatepp.org/upp/trunk@9700 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2016-04-17 12:35:16 +00:00
parent 0932bd4190
commit bcb88320fb
2 changed files with 4 additions and 0 deletions

View file

@ -184,6 +184,8 @@ String QualifyIds(ScopeInfo& nf, const String& k, const String& usings, bool all
String Qualify(const CppBase& base, const String& scope, const String& type, const String& usings)
{
if(type.StartsWith("::"))
return type.Mid(2);
ScopeInfo nf(base, scope);
return QualifyIds(nf, type, usings, true);
}

View file

@ -489,6 +489,8 @@ void AssistEditor::Assist()
String tp;
Vector<String> xp = ReadBack(q, parser.local.GetIndex());
bool isok = false;
if(xp.GetCount() && xp[0].StartsWith("::")) // ::Foo().
xp[0] = xp[0].Mid(2);
for(int i = 0; i < xp.GetCount(); i++)
if(iscib(*xp[i])) {
isok = true;