Skip to content

Commit 5226493

Browse files
committed
libcxx: In gdb test detect execute_mi with feature check instead of version check.
The existing version check can lead to test failures on some distribution packages of gdb where not all components of the version number are integers, such as Fedora where gdb.VERSION can be something like "15.2-4.fc41". Fix it by replacing the version check with a feature check. Pull Request: llvm#132291
1 parent 43f3996 commit 5226493

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

libcxx/test/libcxx/gdb/gdb_pretty_printer_test.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
# we exit.
3131
has_run_tests = False
3232

33-
has_execute_mi = tuple(map(int, gdb.VERSION.split("."))) >= (14, 2)
33+
has_execute_mi = 'execute_mi' in gdb.__dict__
3434

3535
class CheckResult(gdb.Command):
3636
def __init__(self):

0 commit comments

Comments
 (0)