This worries me a little bit
Imagine I have one of these slices with a million elements, and the user gets in and the first thing they do is GetChildAtIndex(750000); then GetChildAtIndex(134621); then GetChildAtIndex(999999)
Now I have allocated one million shared pointers, even though only three are in use
How about std::map<size_t, ValueObjectSP>?
I would also do options.SetLanguage(eLanguageTypeGo) here - in case you ever want to do custom escaping, or the StringPrinter gains any further language-specific abilities
Any reason why you need to use hardcoded formatters here?
Do strings and slices not have simple type names to match against in Go?
If at all possible, I would prefer to see you add formatters by name instead of hardcoded matches. Hardcoded matches are really meant for cases where the predicate you're trying to express is something a type name or regular expression on type names can't capture.
Please add include section comments. Same for other sections.
Please place destructor near constructor.
Please use consistent spacing between methods.
Please use override instead of virtual.
Please place constructor before destructor.
virtual is not needed. Please run clang-tidy modernize-use-override.
Same for GetPluginVersion().
Such comments should be 80 characters long.
Please add headers sections comments. Same for other sections. Clang headers should be before LLDB.
Please add headers sections comments. GoLanguage.h should be in LLDB headers section.
Which sections? I've seen a couple types of section markers in different files, but it's not consistent. Are there documented recommendations for these?
Normal string and slice types can be recognized by name.
Did you format code with Clang-format? Spaces/no spaces between function names and arguments are inconsistent.
This header belongs to Other libraries and framework includes.
This and next include belong to C++ Includes.
I think it's OK to land this, yes
I would still like to think about ways that we can avoid using hardcoded formatters here, but it seems non-trivial and I don't know enough about Go to suggest an obvious solution