Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: ec3fb41c35f912de0ea2ff88d0d507df2fc5d1a7
https://github.com/WebKit/WebKit/commit/ec3fb41c35f912de0ea2ff88d0d507df2fc5d1a7
Author: David Kilzer <[email protected]>
Date: 2026-03-30 (Mon, 30 Mar 2026)
Changed paths:
M Tools/Scripts/dump-class-layout
M Tools/lldb/dump_class_layout_unittest.py
M Tools/lldb/lldbWebKitTester/DumpClassLayoutTesting.cpp
Log Message:
-----------
dump-class-layout should support showing multiple classes
<https://bugs.webkit.org/show_bug.cgi?id=310442>
<rdar://173085155>
Reviewed by Simon Fraser.
Accept multiple `classname` arguments in `dump-class-layout`,
printing each class layout with a blank line between them.
Also add `argv=None` to `main()` so tests can pass arguments directly
without patching `sys.argv`.
Add `TestDumpClassLayoutScript` to verify multi-class argument handling
via `unittest.mock`, loading the script as a Python module with
`importlib.machinery.SourceFileLoader`.
* Tools/Scripts/dump-class-layout:
(main):
* Tools/lldb/dump_class_layout_unittest.py:
- Load `dump-class-layout` as a module via `importlib` for script-level
testing.
(TestDumpClassLayout.serial_test_InheritsFromClassWithPaddedBitfields):
- Drive-by fix to correct the expected output to match the current
compiler-generated layout.
(TestDumpClassLayoutScript.setUp): Add.
(TestDumpClassLayoutScript.tearDown): Add.
(TestDumpClassLayoutScript.test_single_classname_calls_layout_once): Add.
(TestDumpClassLayoutScript.test_multiple_classnames_each_get_layout_called):
Add.
(TestDumpClassLayoutScript.test_blank_line_printed_between_multiple_classes):
Add.
(TestDumpClassLayoutScript.test_blank_line_count_matches_class_count_minus_one):
Add.
(TestDumpClassLayoutScript.test_no_blank_line_for_single_class): Add.
* Tools/lldb/lldbWebKitTester/DumpClassLayoutTesting.cpp:
(InheritsFromClassWithPaddedBitfields):
- Drive-by fix to update the clang record layout comment to match the
current compiler-generated layout.
Canonical link: https://commits.webkit.org/310262@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications