Michael137 wrote: > @Michael137 I looked into adding the diagnostic you asked about and while the > implementation is relatively straightforward, I'm even more convinced that I > don't think it belongs there because it's a semantic rather than a syntax > error. > > We can detect a scope followed by an alternative scope, i.e. something like > `{{foo}|bar}` but what about something like `{foo|bar}`. Just like a scope, > `foo` will always resolve, so technically `bar` is unreachable. Should we > diagnose this too? And what about `{${frame.pc}||bar}`. The empty string > between the two pipes will always resolve. In other words, I don't think this > warrants special casing as there are plenty of other scenarios that trigger > similar behavior that would be much harder to diagnose.
Ok thanks for giving it a shot. I agree it doesn't quite fit the existing syntax diagnostics. We can always choose to revisit if this becomes a big point of confusion for people https://github.com/llvm/llvm-project/pull/137751 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits