jingham accepted this revision. jingham added a comment. This revision is now accepted and ready to land.
Except that you explicitly want to use the expression parser here so you shouldn't use `p` in the test, this seems fine to me. It would be better to have a less fragile strategy for getting an unused region, but short of doing exhaustive searches which have their own problems we haven't come up with anything. So making a better hack seems worthy. Fix the `p` usage and this is good to go. ================ Comment at: lldb/test/API/lang/c/high-mem-global/TestHighMemGlobal.py:29 + + self.expect("p global.c", substrs=[' = 1']) + self.expect("p global.d", substrs=[' = 2']) ---------------- Unless you want to test the alias, it's better to use `expr` rather than `p` in tests. We might some day change what the `p` alias does, and for instance if we get clever about using more static data fetching for `p` then your test won't test what you think it does anymore. ================ Comment at: lldb/test/API/lang/c/high-mem-global/TestHighMemGlobal.py:62 + self.runCmd("p int $global_e = global.e") + self.expect("p $global_c != 1 || $global_d != 2 || $global_e != 3", substrs=[' = true']) ---------------- If you are really worried about false positives here, you could just use funkier values for the three members. Not sure that's really necessary, however. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D137682/new/ https://reviews.llvm.org/D137682 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits