hokein accepted this revision. hokein added a comment. This revision is now accepted and ready to land.
Thanks, this looks great. ================ Comment at: clang/lib/Sema/SemaStmt.cpp:4037 - // Drop the expression. - RetValExp = nullptr; + // Preserve the iniializers in the AST. + RetValExp = AllowRecovery ---------------- iniializers => inializers ================ Comment at: clang/test/AST/ast-dump-recovery.cpp:365 +auto *brokenDeducedReturn(int *x, float *y, double *z) { + // CHECK: FunctionDecl {{.*}} brokenDeducedReturn + if (x) return x; ---------------- nit: I would check the function-decl is invalid as well (this is important). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D116414/new/ https://reviews.llvm.org/D116414 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits