File tree Expand file tree Collapse file tree 3 files changed +11
-4
lines changed
packages/Python/lldbsuite/test Expand file tree Collapse file tree 3 files changed +11
-4
lines changed Original file line number Diff line number Diff line change 52
52
python = sys .executable
53
53
54
54
# The overriden dwarf verison.
55
+ # Don't use this to test the current compiler's
56
+ # DWARF version, as this won't be set if the
57
+ # version isn't overridden.
58
+ # Use lldbplatformutils.getDwarfVersion() instead.
55
59
dwarf_version = 0
56
60
57
61
# Any overridden settings.
Original file line number Diff line number Diff line change 8
8
from lldbsuite .test .decorators import *
9
9
from lldbsuite .test .lldbtest import *
10
10
from lldbsuite .test import lldbutil
11
-
11
+ from lldbsuite . test import lldbplatformutil
12
12
13
13
class NamespaceLookupTestCase (TestBase ):
14
14
def setUp (self ):
@@ -167,7 +167,10 @@ def test_scope_lookup_with_run_command(self):
167
167
self .runToBkpt ("continue" )
168
168
# FIXME: In DWARF 5 with dsyms, the ordering of functions is slightly
169
169
# different, which also hits the same issues mentioned previously.
170
- if configuration .dwarf_version <= 4 or self .getDebugInfo () == "dwarf" :
170
+ if (
171
+ int (lldbplatformutil .getDwarfVersion ()) <= 4
172
+ or self .getDebugInfo () == "dwarf"
173
+ ):
171
174
self .expect_expr ("func()" , result_type = "int" , result_value = "2" )
172
175
173
176
# Continue to BP_ns_scope at ns scope
Original file line number Diff line number Diff line change 6
6
from lldbsuite .test .decorators import *
7
7
from lldbsuite .test .lldbtest import *
8
8
from lldbsuite .test import lldbutil
9
-
9
+ from lldbsuite . test import lldbplatformutil
10
10
11
11
class TypeAndTypeListTestCase (TestBase ):
12
12
def setUp (self ):
@@ -248,7 +248,7 @@ def test(self):
248
248
self .assertEqual (myint_arr_element_type , myint_type )
249
249
250
250
# Test enum methods. Requires DW_AT_enum_class which was added in Dwarf 4.
251
- if configuration . dwarf_version >= 4 :
251
+ if int ( lldbplatformutil . getDwarfVersion ()) >= 4 :
252
252
enum_type = target .FindFirstType ("EnumType" )
253
253
self .assertTrue (enum_type )
254
254
self .DebugSBType (enum_type )
You can’t perform that action at this time.
0 commit comments