[clang] [Serialization] Check for stack exhaustion when reading declarations (PR #79875)

Ilya Biryukov via cfe-commits cfe-commits at lists.llvm.org
Mon Jun 3 07:57:40 PDT 2024


================
@@ -9403,6 +9404,20 @@ DiagnosticBuilder ASTReader::Diag(SourceLocation Loc, unsigned DiagID) const {
   return Diags.Report(Loc, DiagID);
 }
 
+void ASTReader::warnStackExhausted(SourceLocation Loc) {
+  // When Sema is available, avoid duplicate errors. This should be rare.
----------------
ilya-biryukov wrote:

Good catch, I don't think this would necessarily hold in practice in the next few years.

https://github.com/llvm/llvm-project/pull/79875


More information about the cfe-commits mailing list