[Lldb-commits] [PATCH] D114008: Draft PR for the deque, stack, queue lldb data formatters
Danil Stefaniuc via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Fri Nov 26 03:37:06 PST 2021
danilashtefan added a comment.
Hi @labath, Thank you so much for your comment and correction. The initial version of the test was the following, with array of ValueCheck objects:
`def check(self, var_name, size):
var = self.findVariable(var_name)
self.assertEqual(var.GetNumChildren(), size)
children = []
for i in range(100):
children.insert(0,ValueCheck(value={i, i + 1, i + 2}))
children.append(ValueCheck(value={-i, -(i + 1), -(i + 2)}))
self.expect_var_path(var_name, type=self.getVariableType(var_name), children=children)`
However, the following error pops up in the `expected_var_path`: `AssertionError: {99, 100, 101} != None : Checking child with index 0:`. The reason is that `child.GetValue()`that is invoked inside gives None in case it is a complex structure. This is why me and @wallace decided to go with a printing test.
If I did not get you right, I would be glad if you could describe your solution more, so I can implement it. Many thanks!
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D114008/new/
https://reviews.llvm.org/D114008
More information about the lldb-commits
mailing list