Просмотр исходного кода

Move C++ interop related `check` code files to a `cpp` dir (#6065)

Context:
https://github.com/carbon-language/carbon-lang/pull/5891#pullrequestreview-3178216893
Boaz Brickner 7 месяцев назад
Родитель
Сommit
f29515fe4e

+ 10 - 10
toolchain/check/BUILD

@@ -21,11 +21,11 @@ cc_library(
         "context.cpp",
         "control_flow.cpp",
         "convert.cpp",
-        "cpp_custom_type_mapping.cpp",
-        "cpp_import.cpp",
-        "cpp_overload_resolution.cpp",
-        "cpp_thunk.cpp",
-        "cpp_type_mapping.cpp",
+        "cpp/custom_type_mapping.cpp",
+        "cpp/import.cpp",
+        "cpp/overload_resolution.cpp",
+        "cpp/thunk.cpp",
+        "cpp/type_mapping.cpp",
         "decl_name_stack.cpp",
         "deduce.cpp",
         "deferred_definition_worklist.cpp",
@@ -70,11 +70,11 @@ cc_library(
         "context.h",
         "control_flow.h",
         "convert.h",
-        "cpp_custom_type_mapping.h",
-        "cpp_import.h",
-        "cpp_overload_resolution.h",
-        "cpp_thunk.h",
-        "cpp_type_mapping.h",
+        "cpp/custom_type_mapping.h",
+        "cpp/import.h",
+        "cpp/overload_resolution.h",
+        "cpp/thunk.h",
+        "cpp/type_mapping.h",
         "decl_introducer_state.h",
         "decl_name_stack.h",
         "deduce.h",

+ 2 - 2
toolchain/check/call.cpp

@@ -10,8 +10,8 @@
 #include "toolchain/check/context.h"
 #include "toolchain/check/control_flow.h"
 #include "toolchain/check/convert.h"
-#include "toolchain/check/cpp_overload_resolution.h"
-#include "toolchain/check/cpp_thunk.h"
+#include "toolchain/check/cpp/overload_resolution.h"
+#include "toolchain/check/cpp/thunk.h"
 #include "toolchain/check/deduce.h"
 #include "toolchain/check/facet_type.h"
 #include "toolchain/check/function.h"

+ 1 - 1
toolchain/check/check.cpp

@@ -11,7 +11,7 @@
 #include "common/map.h"
 #include "toolchain/check/check_unit.h"
 #include "toolchain/check/context.h"
-#include "toolchain/check/cpp_import.h"
+#include "toolchain/check/cpp/import.h"
 #include "toolchain/check/diagnostic_emitter.h"
 #include "toolchain/check/diagnostic_helpers.h"
 #include "toolchain/diagnostics/diagnostic.h"

+ 1 - 1
toolchain/check/check_unit.cpp

@@ -17,7 +17,7 @@
 #include "llvm/Support/VirtualFileSystem.h"
 #include "toolchain/base/fixed_size_value_store.h"
 #include "toolchain/base/kind_switch.h"
-#include "toolchain/check/cpp_import.h"
+#include "toolchain/check/cpp/import.h"
 #include "toolchain/check/diagnostic_helpers.h"
 #include "toolchain/check/generic.h"
 #include "toolchain/check/handle.h"

+ 1 - 1
toolchain/check/cpp_custom_type_mapping.cpp → toolchain/check/cpp/custom_type_mapping.cpp

@@ -2,7 +2,7 @@
 // Exceptions. See /LICENSE for license information.
 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
 
-#include "toolchain/check/cpp_custom_type_mapping.h"
+#include "toolchain/check/cpp/custom_type_mapping.h"
 
 #include "clang/AST/DeclCXX.h"
 #include "clang/AST/DeclTemplate.h"

+ 0 - 0
toolchain/check/cpp_custom_type_mapping.h → toolchain/check/cpp/custom_type_mapping.h


+ 3 - 3
toolchain/check/cpp_import.cpp → toolchain/check/cpp/import.cpp

@@ -2,7 +2,7 @@
 // Exceptions. See /LICENSE for license information.
 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
 
-#include "toolchain/check/cpp_import.h"
+#include "toolchain/check/cpp/import.h"
 
 #include <memory>
 #include <optional>
@@ -31,8 +31,8 @@
 #include "toolchain/check/context.h"
 #include "toolchain/check/control_flow.h"
 #include "toolchain/check/convert.h"
-#include "toolchain/check/cpp_custom_type_mapping.h"
-#include "toolchain/check/cpp_thunk.h"
+#include "toolchain/check/cpp/custom_type_mapping.h"
+#include "toolchain/check/cpp/thunk.h"
 #include "toolchain/check/diagnostic_helpers.h"
 #include "toolchain/check/eval.h"
 #include "toolchain/check/function.h"

+ 0 - 0
toolchain/check/cpp_import.h → toolchain/check/cpp/import.h


+ 3 - 3
toolchain/check/cpp_overload_resolution.cpp → toolchain/check/cpp/overload_resolution.cpp

@@ -2,12 +2,12 @@
 // Exceptions. See /LICENSE for license information.
 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
 
-#include "toolchain/check/cpp_overload_resolution.h"
+#include "toolchain/check/cpp/overload_resolution.h"
 
 #include "clang/Sema/Overload.h"
 #include "clang/Sema/Sema.h"
-#include "toolchain/check/cpp_import.h"
-#include "toolchain/check/cpp_type_mapping.h"
+#include "toolchain/check/cpp/import.h"
+#include "toolchain/check/cpp/type_mapping.h"
 #include "toolchain/sem_ir/expr_info.h"
 #include "toolchain/sem_ir/typed_insts.h"
 

+ 0 - 0
toolchain/check/cpp_overload_resolution.h → toolchain/check/cpp/overload_resolution.h


+ 1 - 1
toolchain/check/cpp_thunk.cpp → toolchain/check/cpp/thunk.cpp

@@ -2,7 +2,7 @@
 // Exceptions. See /LICENSE for license information.
 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
 
-#include "toolchain/check/cpp_thunk.h"
+#include "toolchain/check/cpp/thunk.h"
 
 #include "clang/AST/GlobalDecl.h"
 #include "clang/AST/Mangle.h"

+ 0 - 0
toolchain/check/cpp_thunk.h → toolchain/check/cpp/thunk.h


+ 1 - 1
toolchain/check/cpp_type_mapping.cpp → toolchain/check/cpp/type_mapping.cpp

@@ -2,7 +2,7 @@
 // Exceptions. See /LICENSE for license information.
 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
 
-#include "toolchain/check/cpp_type_mapping.h"
+#include "toolchain/check/cpp/type_mapping.h"
 
 #include <cstddef>
 #include <iostream>

+ 0 - 0
toolchain/check/cpp_type_mapping.h → toolchain/check/cpp/type_mapping.h


+ 1 - 1
toolchain/check/name_lookup.cpp

@@ -6,7 +6,7 @@
 
 #include <optional>
 
-#include "toolchain/check/cpp_import.h"
+#include "toolchain/check/cpp/import.h"
 #include "toolchain/check/generic.h"
 #include "toolchain/check/import.h"
 #include "toolchain/check/import_ref.h"

+ 1 - 1
toolchain/check/operator.cpp

@@ -8,7 +8,7 @@
 
 #include "toolchain/check/call.h"
 #include "toolchain/check/context.h"
-#include "toolchain/check/cpp_import.h"
+#include "toolchain/check/cpp/import.h"
 #include "toolchain/check/generic.h"
 #include "toolchain/check/member_access.h"
 #include "toolchain/check/name_lookup.h"

+ 1 - 1
toolchain/check/type_completion.cpp

@@ -6,7 +6,7 @@
 
 #include "llvm/ADT/SmallVector.h"
 #include "toolchain/base/kind_switch.h"
-#include "toolchain/check/cpp_import.h"
+#include "toolchain/check/cpp/import.h"
 #include "toolchain/check/generic.h"
 #include "toolchain/check/inst.h"
 #include "toolchain/check/type.h"