Explorer: Add methods to trace for line prefixes (#3076)

Defines methods into `TraceStream` for adding line prefixes. Instead of
directly using string literals.

Example usage,
```
trace_stream_->Start() << "declaring ... " << ... ;
```
will result in,
```
->> declaring ... 
```
This commit is contained in:
Prabhat Sachdeva
2023-08-09 19:05:19 +00:00
committed by GitHub
parent a67aeb5724
commit 0bcba9d05e
19 changed files with 710 additions and 682 deletions
+1 -1
View File
@@ -416,7 +416,7 @@ auto ImplScope::TryResolveInterfaceHere(
// TODO: Add indentation when printing the parents.
void ImplScope::Print(llvm::raw_ostream& out) const {
llvm::ListSeparator sep(",\n ");
out << " + "
out << " "
<< "[";
for (const ImplFact& impl : impl_facts_) {
out << sep << "`" << *(impl.type) << "` as `" << *(impl.interface) << "`";