From b922a24f7647e47dd8148e8cf980f66cce58282e Mon Sep 17 00:00:00 2001 From: Ilya Biryukov Date: Thu, 31 Jul 2025 15:32:59 +0200 Subject: [PATCH] [Clang] Flush minimization hints after writing This helps to get well-formed output if Clang crashes after that point. --- clang/lib/Frontend/FrontendAction.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/clang/lib/Frontend/FrontendAction.cpp b/clang/lib/Frontend/FrontendAction.cpp index 1d82fc775b28a..cf081830c95bb 100644 --- a/clang/lib/Frontend/FrontendAction.cpp +++ b/clang/lib/Frontend/FrontendAction.cpp @@ -226,6 +226,8 @@ class DeserializedDeclsSourceRangePrinter : public ASTConsumer, } *OS << " ]\n"; *OS << "}\n"; + + OS->flush(); } };