Include Stmt.h where it seems to be necessary for modules builds
authorReid Kleckner <rnk@google.com>
Mon, 9 Dec 2019 21:03:06 +0000 (13:03 -0800)
committerReid Kleckner <rnk@google.com>
Mon, 9 Dec 2019 21:08:44 +0000 (13:08 -0800)
Summary:
After 60573ae6fe50 removed an include of Expr.h from ASTContext.h, this
header fails to compile in some modular build configurations. I have not
been able to reproduce the problem locally. The header compiles fine in
isolation. However, based on reading the code, it seems like it would
require Stmt to be complete. Based on that intuition, we decided to add the
include.

Reviewers: rdhindsa

Subscribers: cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D71222

clang/include/clang/Tooling/Refactoring/ASTSelection.h

index b87ed28..9122b5c 100644 (file)
@@ -10,6 +10,7 @@
 #define LLVM_CLANG_TOOLING_REFACTOR_AST_SELECTION_H
 
 #include "clang/AST/ASTTypeTraits.h"
+#include "clang/AST/Stmt.h"
 #include "clang/Basic/LLVM.h"
 #include "clang/Basic/SourceLocation.h"
 #include <vector>