Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / lldb / test / API / lang / c / sizeof / TestCSizeof.py
blobfcd155ea11c981ed4ffb3df652e446b6ee5b9f59
1 import lldb
2 from lldbsuite.test.decorators import *
3 from lldbsuite.test.lldbtest import *
4 from lldbsuite.test import lldbutil
7 class TestCase(TestBase):
8 def test(self):
9 self.build()
10 self.createTestTarget()
12 # Empty structs are not allowed in C, but Clang/GCC allow them and
13 # give them a size of 0.
14 self.expect_expr("sizeof(Empty) == sizeof_empty", result_value="true")
15 self.expect_expr(
16 "sizeof(EmptyMember) == sizeof_empty_member", result_value="true"
18 self.expect_expr("sizeof(SingleMember) == sizeof_single", result_value="true")
19 self.expect_expr("sizeof(PaddingMember) == sizeof_padding", result_value="true")