How to Set a Conditional Breakpoint When Debugging Rust with LLDB

Bottom Line: A little Python can help LLDB break on String contents in Rust. A few months ago I was trying to debug some Rust code that was misbehaving. The bug was in a function that was run hundreds of thousands of times, but I had made a logic error somewhere that only seemed to manifest in a very small fraction of the cases. I had gathered a few examples that were reliably misbehaving, so I…