Fixed name lookups for names that contain "::" but aren't actually C++ qualified...
authorGreg Clayton <gclayton@apple.com>
Wed, 22 Oct 2014 21:47:13 +0000 (21:47 +0000)
committerGreg Clayton <gclayton@apple.com>
Wed, 22 Oct 2014 21:47:13 +0000 (21:47 +0000)
commitc3795409c91affb53764d135a1c112d9bd808eef
treef2ed0e3340cc6e7805249d1d91d143df46176175
parentfa226b74d18ff910fe069377fec7d05ee1c61975
Fixed name lookups for names that contain "::" but aren't actually C++ qualified C++ names.

To do this, I fixed the  CPPLanguageRuntime::StripNamespacesFromVariableName() function to use a regular expression that correctly determines if the name passed to it is a qualfied C++ name like "a::b::c" or "b::c". The old version of this function was treating '__54-[NSUserScriptTask executeWithInterpreter:arguments::]_block_invoke' as a match with a basename of ']_block_invoke'.

Also fixed a case in the by name lookup of functions where we wouldn't look for the full name if we actually tried to call CPPLanguageRuntime::StripNamespacesFromVariableName() and got an empty basename back.

<rdar://problem/18527866>

llvm-svn: 220432
lldb/source/Core/Module.cpp
lldb/source/Target/CPPLanguageRuntime.cpp