Changed the SymbolFile::FindFunction() function calls to only return 
lldb_private::Function objects. Previously the SymbolFileSymtab subclass
would return lldb_private::Symbol objects when it was asked to find functions.

The Module::FindFunctions (...) now take a boolean "bool include_symbols" so
that the module can track down functions and symbols, yet functions are found
by the SymbolFile plug-ins (through the SymbolVendor class), and symbols are
gotten through the ObjectFile plug-ins.

Fixed and issue where the DWARF parser might run into incomplete class member
function defintions which would make clang mad when we tried to make certain
member functions with invalid number of parameters (such as an operator=
operator that had no parameters). Now we just avoid and don't complete these
incomplete functions.

llvm-svn: 124359
diff --git a/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp b/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp
index 56141bc..f524a51 100644
--- a/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp
+++ b/lldb/source/Plugins/SymbolFile/Symtab/SymbolFileSymtab.cpp
@@ -323,25 +323,11 @@
     Timer scoped_timer (__PRETTY_FUNCTION__,
                         "SymbolFileSymtab::FindFunctions (name = '%s')",
                         name.GetCString());
-
-    Symtab *symtab = m_obj_file->GetSymtab();
-    if (symtab)
-    {
-        const uint32_t start_size = sc_list.GetSize();
-        std::vector<uint32_t> symbol_indexes;
-        symtab->FindAllSymbolsWithNameAndType (name, eSymbolTypeCode, Symtab::eDebugAny, Symtab::eVisibilityAny, symbol_indexes);
-        const uint32_t num_matches = symbol_indexes.size();
-        if (num_matches)
-        {
-            SymbolContext sc(m_obj_file->GetModule());
-            for (uint32_t i=0; i<num_matches; i++)
-            {
-                sc.symbol = symtab->SymbolAtIndex(symbol_indexes[i]);
-                sc_list.Append(sc);
-            }
-        }
-        return sc_list.GetSize() - start_size;
-    }
+    // If we ever support finding STABS or COFF debug info symbols, 
+    // we will need to add support here. We are not trying to find symbols
+    // here, just "lldb_private::Function" objects that come from complete 
+    // debug information. Any symbol queries should go through the symbol
+    // table itself in the module's object file.
     return 0;
 }
 
@@ -351,7 +337,11 @@
     Timer scoped_timer (__PRETTY_FUNCTION__,
                         "SymbolFileSymtab::FindFunctions (regex = '%s')",
                         regex.GetText());
-
+    // If we ever support finding STABS or COFF debug info symbols, 
+    // we will need to add support here. We are not trying to find symbols
+    // here, just "lldb_private::Function" objects that come from complete 
+    // debug information. Any symbol queries should go through the symbol
+    // table itself in the module's object file.
     return 0;
 }