JDevlieghere added a comment. In the future please include context with the diff (-U9999 should do the trick), it makes reviewing a lot easier.
Have you considered wrapping raw strings in llvm's `StringRef`s? It looks like lldb-mi is already using some ADT classes from llvm. Unfortunately we cannot use those in the SB interface, but they're a lot safer. They have a `.str()` which does the right thing and returns an empty string when the raw string is a `nullptr`. Personally I would very much prefer that over the `This.or(That)` pattern, but if you really wanted that you could have an Optional<StringRef> and do `getValueOr()` as Shafik suggested. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55653/new/ https://reviews.llvm.org/D55653 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits