Răsfoiți Sursa

Add workaround for StatementBlock declaration circularity (#1342)

This won't be visible everywhere, but I think something's needed -- this workaround is temporary while I work on a bigger change to semantics.
Jon Ross-Perkins 3 ani în urmă
părinte
comite
6dd08d09ac
1 a modificat fișierele cu 5 adăugiri și 0 ștergeri
  1. 5 0
      toolchain/semantics/nodes/function.h

+ 5 - 0
toolchain/semantics/nodes/function.h

@@ -13,6 +13,11 @@
 #include "toolchain/semantics/nodes/declared_name.h"
 #include "toolchain/semantics/nodes/declared_name.h"
 #include "toolchain/semantics/nodes/pattern_binding.h"
 #include "toolchain/semantics/nodes/pattern_binding.h"
 
 
+// TODO: StatementBlock has some circularity in its forward declarations that
+// needs to be fixed. These includes are a workaround.
+#include "toolchain/semantics/nodes/expression_statement.h"
+#include "toolchain/semantics/nodes/return.h"
+
 namespace Carbon::Semantics {
 namespace Carbon::Semantics {
 
 
 // Represents `fn name(params...) [-> return_expr] body`.
 // Represents `fn name(params...) [-> return_expr] body`.