cjdb added inline comments.

================
Comment at: clang/lib/Frontend/SARIFDiagnosticPrinter.cpp:53
+  OS.flush();
+}
+
----------------
aaron.ballman wrote:
> Should we be invalidating that `SARIFDiag` object here so the printer cannot 
> be used after the source file has ended?
I suggested that we don't do this, because the next run of `BeginSourceFile` 
can take care of that when making the new `SARIFDiagnostic`. However, if we 
were to put an assert at the top of every member function other than 
`BeginSourceFile` to ensure that SARIFDiag isn't null (and one at the top of 
`BeginSourceFile` to ensure that it _is_), I think there might be good value in 
re-adding this.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D131632/new/

https://reviews.llvm.org/D131632

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to