From ffe7fa64b236cecb86f977e68f42586806559e95 Mon Sep 17 00:00:00 2001 From: Tulio Magno Quites Machado Filho Date: Wed, 9 Aug 2023 19:08:51 -0300 Subject: [PATCH] Update lldb output in LLVM 17.0 There have been a few changes that require to modify the regexes used in lldb-std-vector-prettyprint and in python-embedded-interpreter. --- lldb-std-vector-prettyprint/test.sh | 10 +++++++++- python-embedded-interpreter/test.sh | 4 ++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/lldb-std-vector-prettyprint/test.sh b/lldb-std-vector-prettyprint/test.sh index 7ca0d8e..d6740ad 100755 --- a/lldb-std-vector-prettyprint/test.sh +++ b/lldb-std-vector-prettyprint/test.sh @@ -4,8 +4,16 @@ g++ -g test.cpp lldb -b -o 'breakpoint set --file test.cpp --line 7' -o run -o 'p v' -- a.out | tee lldb.log +# Starting with LLVM 17.0, the expected output is: +# (std::vector) size=1 { +# [0] = 2 + +# In LLVM 16.0, the expected output is: +# (std::vector >) $0 = size=1 { +# [0] = 2 + test `grep \ - -e '(std::vector >) $0 = size=1 {' \ + -e '(std::vector \)\?>) \($0 = \)\?size=1 {' \ -e '\[0\] = 2' \ lldb.log \ | wc -l` -eq 2 diff --git a/python-embedded-interpreter/test.sh b/python-embedded-interpreter/test.sh index e495f58..e495c66 100755 --- a/python-embedded-interpreter/test.sh +++ b/python-embedded-interpreter/test.sh @@ -11,8 +11,8 @@ lldb -b -o 'breakpoint set --file test.cpp --line 8' \ -- a.out | tee lldb.log test `grep \ - -e '(int) $0 = 1' \ - -e '(float) $1 = 1' \ + -e '(int) \($0 = \)\?1' \ + -e '(float) \($1 = \)\?1' \ lldb.log \ | wc -l` -eq 2