Don't try to parse the line table when it isn't specified

Previously we tried to parse the line table even if a compile unit
had no DW_AT_stmt_list atribute. The problem happens when a compiler
generates debug info for a compile unit but doesn't generate any line
info.

llvm-svn: 257335
diff --git a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
index 423b73d..2088864 100644
--- a/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
+++ b/lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
@@ -1065,12 +1065,17 @@
             const char * cu_comp_dir = resolveCompDir(cu_die.GetAttributeValueAsString(DW_AT_comp_dir, nullptr));
 
             const dw_offset_t stmt_list = cu_die.GetAttributeValueAsUnsigned(DW_AT_stmt_list, DW_INVALID_OFFSET);
-
-            // All file indexes in DWARF are one based and a file of index zero is
-            // supposed to be the compile unit itself.
-            support_files.Append (*sc.comp_unit);
-
-            return DWARFDebugLine::ParseSupportFiles(sc.comp_unit->GetModule(), get_debug_line_data(), cu_comp_dir, stmt_list, support_files);
+            if (stmt_list != DW_INVALID_OFFSET)
+            {
+                // All file indexes in DWARF are one based and a file of index zero is
+                // supposed to be the compile unit itself.
+                support_files.Append (*sc.comp_unit);
+                return DWARFDebugLine::ParseSupportFiles(sc.comp_unit->GetModule(),
+                                                         get_debug_line_data(),
+                                                         cu_comp_dir,
+                                                         stmt_list,
+                                                         support_files);
+            }
         }
     }
     return false;