|
|
@@ -27,8 +27,13 @@ library "[[@TEST_NAME]]";
|
|
|
import Cpp library "decl_value_param_type.h";
|
|
|
|
|
|
fn F() {
|
|
|
- //@dump-sem-ir-begin
|
|
|
- // TODO: This should fail on the fact `C` is declared and not defined.
|
|
|
+ // CHECK:STDERR: fail_todo_import_decl_value_param_type.carbon:[[@LINE+14]]:3: error: semantics TODO: `Unsupported: Record declarations without a definition` [SemanticsTodo]
|
|
|
+ // CHECK:STDERR: Cpp.foo({});
|
|
|
+ // CHECK:STDERR: ^~~~~~~
|
|
|
+ // CHECK:STDERR: fail_todo_import_decl_value_param_type.carbon:[[@LINE+11]]:3: note: in `Cpp` name lookup for `foo` [InCppNameLookup]
|
|
|
+ // CHECK:STDERR: Cpp.foo({});
|
|
|
+ // CHECK:STDERR: ^~~~~~~
|
|
|
+ // CHECK:STDERR:
|
|
|
// CHECK:STDERR: fail_todo_import_decl_value_param_type.carbon:[[@LINE+7]]:3: error: semantics TODO: `Unsupported: parameter type: class C` [SemanticsTodo]
|
|
|
// CHECK:STDERR: Cpp.foo({});
|
|
|
// CHECK:STDERR: ^~~~~~~
|
|
|
@@ -37,7 +42,6 @@ fn F() {
|
|
|
// CHECK:STDERR: ^~~~~~~
|
|
|
// CHECK:STDERR:
|
|
|
Cpp.foo({});
|
|
|
- //@dump-sem-ir-end
|
|
|
}
|
|
|
|
|
|
// ============================================================================
|
|
|
@@ -50,7 +54,7 @@ class C {};
|
|
|
|
|
|
auto foo(C) -> void;
|
|
|
|
|
|
-// --- fail_todo_import_definition_no_data_members_value_param_type.carbon
|
|
|
+// --- import_definition_no_data_members_value_param_type.carbon
|
|
|
|
|
|
library "[[@TEST_NAME]]";
|
|
|
|
|
|
@@ -58,13 +62,6 @@ import Cpp library "definition_no_data_members_value_param_type.h";
|
|
|
|
|
|
fn F() {
|
|
|
//@dump-sem-ir-begin
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_no_data_members_value_param_type.carbon:[[@LINE+7]]:3: error: semantics TODO: `Unsupported: parameter type: class C` [SemanticsTodo]
|
|
|
- // CHECK:STDERR: Cpp.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_no_data_members_value_param_type.carbon:[[@LINE+4]]:3: note: in `Cpp` name lookup for `foo` [InCppNameLookup]
|
|
|
- // CHECK:STDERR: Cpp.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR:
|
|
|
Cpp.foo({});
|
|
|
//@dump-sem-ir-end
|
|
|
}
|
|
|
@@ -83,7 +80,7 @@ class C {
|
|
|
|
|
|
auto foo(C) -> void;
|
|
|
|
|
|
-// --- fail_todo_import_definition_single_data_member_value_param_type.carbon
|
|
|
+// --- import_definition_single_data_member_value_param_type.carbon
|
|
|
|
|
|
library "[[@TEST_NAME]]";
|
|
|
|
|
|
@@ -91,13 +88,6 @@ import Cpp library "definition_single_data_member_value_param_type.h";
|
|
|
|
|
|
fn F() {
|
|
|
//@dump-sem-ir-begin
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_single_data_member_value_param_type.carbon:[[@LINE+7]]:3: error: semantics TODO: `Unsupported: parameter type: class C` [SemanticsTodo]
|
|
|
- // CHECK:STDERR: Cpp.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_single_data_member_value_param_type.carbon:[[@LINE+4]]:3: note: in `Cpp` name lookup for `foo` [InCppNameLookup]
|
|
|
- // CHECK:STDERR: Cpp.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR:
|
|
|
Cpp.foo({});
|
|
|
//@dump-sem-ir-end
|
|
|
}
|
|
|
@@ -118,7 +108,7 @@ class C {
|
|
|
|
|
|
auto foo(C) -> void;
|
|
|
|
|
|
-// --- fail_todo_import_definition_multiple_data_members_value_param_type.carbon
|
|
|
+// --- import_definition_multiple_data_members_value_param_type.carbon
|
|
|
|
|
|
library "[[@TEST_NAME]]";
|
|
|
|
|
|
@@ -126,13 +116,6 @@ import Cpp library "definition_multiple_data_members_value_param_type.h";
|
|
|
|
|
|
fn F() {
|
|
|
//@dump-sem-ir-begin
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_multiple_data_members_value_param_type.carbon:[[@LINE+7]]:3: error: semantics TODO: `Unsupported: parameter type: class C` [SemanticsTodo]
|
|
|
- // CHECK:STDERR: Cpp.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_multiple_data_members_value_param_type.carbon:[[@LINE+4]]:3: note: in `Cpp` name lookup for `foo` [InCppNameLookup]
|
|
|
- // CHECK:STDERR: Cpp.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR:
|
|
|
Cpp.foo({});
|
|
|
//@dump-sem-ir-end
|
|
|
}
|
|
|
@@ -147,7 +130,7 @@ namespace N { class C {}; }
|
|
|
|
|
|
auto foo(N::C) -> void;
|
|
|
|
|
|
-// --- fail_todo_import_definition_in_namespace_value_param_type.carbon
|
|
|
+// --- import_definition_in_namespace_value_param_type.carbon
|
|
|
|
|
|
library "[[@TEST_NAME]]";
|
|
|
|
|
|
@@ -155,13 +138,6 @@ import Cpp library "definition_in_namespace_value_param_type.h";
|
|
|
|
|
|
fn F() {
|
|
|
//@dump-sem-ir-begin
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_in_namespace_value_param_type.carbon:[[@LINE+7]]:3: error: semantics TODO: `Unsupported: parameter type: class N::C` [SemanticsTodo]
|
|
|
- // CHECK:STDERR: Cpp.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_in_namespace_value_param_type.carbon:[[@LINE+4]]:3: note: in `Cpp` name lookup for `foo` [InCppNameLookup]
|
|
|
- // CHECK:STDERR: Cpp.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR:
|
|
|
Cpp.foo({});
|
|
|
//@dump-sem-ir-end
|
|
|
}
|
|
|
@@ -177,7 +153,7 @@ namespace N1 {
|
|
|
auto foo(N2::C) -> void;
|
|
|
}
|
|
|
|
|
|
-// --- fail_todo_import_definition_in_relative_namespace_value_param_type.carbon
|
|
|
+// --- import_definition_in_relative_namespace_value_param_type.carbon
|
|
|
|
|
|
library "[[@TEST_NAME]]";
|
|
|
|
|
|
@@ -185,13 +161,6 @@ import Cpp library "definition_in_relative_namespace_value_param_type.h";
|
|
|
|
|
|
fn F() {
|
|
|
//@dump-sem-ir-begin
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_in_relative_namespace_value_param_type.carbon:[[@LINE+7]]:3: error: semantics TODO: `Unsupported: parameter type: class N1::N2::C` [SemanticsTodo]
|
|
|
- // CHECK:STDERR: Cpp.N1.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~~~~
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_in_relative_namespace_value_param_type.carbon:[[@LINE+4]]:3: note: in `Cpp` name lookup for `foo` [InCppNameLookup]
|
|
|
- // CHECK:STDERR: Cpp.N1.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~~~~
|
|
|
- // CHECK:STDERR:
|
|
|
Cpp.N1.foo({});
|
|
|
//@dump-sem-ir-end
|
|
|
}
|
|
|
@@ -208,7 +177,7 @@ class C {
|
|
|
|
|
|
auto foo(C) -> void;
|
|
|
|
|
|
-// --- fail_todo_import_definition_and_static_method_call_before.carbon
|
|
|
+// --- import_definition_and_static_method_call_before.carbon
|
|
|
|
|
|
library "[[@TEST_NAME]]";
|
|
|
|
|
|
@@ -217,18 +186,11 @@ import Cpp library "definition_with_static_method.h";
|
|
|
fn F() {
|
|
|
//@dump-sem-ir-begin
|
|
|
Cpp.C.bar();
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_and_static_method_call_before.carbon:[[@LINE+7]]:3: error: semantics TODO: `Unsupported: parameter type: class C` [SemanticsTodo]
|
|
|
- // CHECK:STDERR: Cpp.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_and_static_method_call_before.carbon:[[@LINE+4]]:3: note: in `Cpp` name lookup for `foo` [InCppNameLookup]
|
|
|
- // CHECK:STDERR: Cpp.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR:
|
|
|
Cpp.foo({});
|
|
|
//@dump-sem-ir-end
|
|
|
}
|
|
|
|
|
|
-// --- fail_todo_import_definition_and_static_method_call_after.carbon
|
|
|
+// --- import_definition_and_static_method_call_after.carbon
|
|
|
|
|
|
library "[[@TEST_NAME]]";
|
|
|
|
|
|
@@ -236,13 +198,6 @@ import Cpp library "definition_with_static_method.h";
|
|
|
|
|
|
fn F() {
|
|
|
//@dump-sem-ir-begin
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_and_static_method_call_after.carbon:[[@LINE+7]]:3: error: semantics TODO: `Unsupported: parameter type: class C` [SemanticsTodo]
|
|
|
- // CHECK:STDERR: Cpp.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_and_static_method_call_after.carbon:[[@LINE+4]]:3: note: in `Cpp` name lookup for `foo` [InCppNameLookup]
|
|
|
- // CHECK:STDERR: Cpp.foo({});
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR:
|
|
|
Cpp.foo({});
|
|
|
Cpp.C.bar();
|
|
|
//@dump-sem-ir-end
|
|
|
@@ -265,22 +220,22 @@ library "[[@TEST_NAME]]";
|
|
|
import Cpp library "decl_pointer_param_type.h";
|
|
|
|
|
|
// CHECK:STDERR: fail_todo_import_decl_pointer_param_type.carbon:[[@LINE+7]]:9: error: semantics TODO: `Unsupported: Record declarations without a definition` [SemanticsTodo]
|
|
|
-// CHECK:STDERR: fn F(s: Cpp.C*) {
|
|
|
+// CHECK:STDERR: fn F(c: Cpp.C*) {
|
|
|
// CHECK:STDERR: ^~~~~
|
|
|
// CHECK:STDERR: fail_todo_import_decl_pointer_param_type.carbon:[[@LINE+4]]:9: note: in `Cpp` name lookup for `C` [InCppNameLookup]
|
|
|
-// CHECK:STDERR: fn F(s: Cpp.C*) {
|
|
|
+// CHECK:STDERR: fn F(c: Cpp.C*) {
|
|
|
// CHECK:STDERR: ^~~~~
|
|
|
// CHECK:STDERR:
|
|
|
-fn F(s: Cpp.C*) {
|
|
|
+fn F(c: Cpp.C*) {
|
|
|
//@dump-sem-ir-begin
|
|
|
// CHECK:STDERR: fail_todo_import_decl_pointer_param_type.carbon:[[@LINE+7]]:3: error: semantics TODO: `Unsupported: parameter type: class C *` [SemanticsTodo]
|
|
|
- // CHECK:STDERR: Cpp.foo(s);
|
|
|
+ // CHECK:STDERR: Cpp.foo(c);
|
|
|
// CHECK:STDERR: ^~~~~~~
|
|
|
// CHECK:STDERR: fail_todo_import_decl_pointer_param_type.carbon:[[@LINE+4]]:3: note: in `Cpp` name lookup for `foo` [InCppNameLookup]
|
|
|
- // CHECK:STDERR: Cpp.foo(s);
|
|
|
+ // CHECK:STDERR: Cpp.foo(c);
|
|
|
// CHECK:STDERR: ^~~~~~~
|
|
|
// CHECK:STDERR:
|
|
|
- Cpp.foo(s);
|
|
|
+ Cpp.foo(c);
|
|
|
//@dump-sem-ir-end
|
|
|
}
|
|
|
|
|
|
@@ -300,16 +255,16 @@ library "[[@TEST_NAME]]";
|
|
|
|
|
|
import Cpp library "definition_pointer_param_type.h";
|
|
|
|
|
|
-fn F(s: Cpp.C*) {
|
|
|
+fn F(c: Cpp.C*) {
|
|
|
//@dump-sem-ir-begin
|
|
|
// CHECK:STDERR: fail_todo_import_definition_pointer_param_type.carbon:[[@LINE+7]]:3: error: semantics TODO: `Unsupported: parameter type: class C *` [SemanticsTodo]
|
|
|
- // CHECK:STDERR: Cpp.foo(s);
|
|
|
+ // CHECK:STDERR: Cpp.foo(c);
|
|
|
// CHECK:STDERR: ^~~~~~~
|
|
|
// CHECK:STDERR: fail_todo_import_definition_pointer_param_type.carbon:[[@LINE+4]]:3: note: in `Cpp` name lookup for `foo` [InCppNameLookup]
|
|
|
- // CHECK:STDERR: Cpp.foo(s);
|
|
|
+ // CHECK:STDERR: Cpp.foo(c);
|
|
|
// CHECK:STDERR: ^~~~~~~
|
|
|
// CHECK:STDERR:
|
|
|
- Cpp.foo(s);
|
|
|
+ Cpp.foo(c);
|
|
|
//@dump-sem-ir-end
|
|
|
}
|
|
|
|
|
|
@@ -330,7 +285,13 @@ library "[[@TEST_NAME]]";
|
|
|
import Cpp library "decl_value_return_type.h";
|
|
|
|
|
|
fn F() {
|
|
|
- // TODO: This should fail on the fact `C` is declared and not defined.
|
|
|
+ // CHECK:STDERR: fail_todo_import_decl_value_return_type.carbon:[[@LINE+14]]:3: error: semantics TODO: `Unsupported: Record declarations without a definition` [SemanticsTodo]
|
|
|
+ // CHECK:STDERR: Cpp.foo();
|
|
|
+ // CHECK:STDERR: ^~~~~~~
|
|
|
+ // CHECK:STDERR: fail_todo_import_decl_value_return_type.carbon:[[@LINE+11]]:3: note: in `Cpp` name lookup for `foo` [InCppNameLookup]
|
|
|
+ // CHECK:STDERR: Cpp.foo();
|
|
|
+ // CHECK:STDERR: ^~~~~~~
|
|
|
+ // CHECK:STDERR:
|
|
|
// CHECK:STDERR: fail_todo_import_decl_value_return_type.carbon:[[@LINE+7]]:3: error: semantics TODO: `Unsupported: return type: class C` [SemanticsTodo]
|
|
|
// CHECK:STDERR: Cpp.foo();
|
|
|
// CHECK:STDERR: ^~~~~~~
|
|
|
@@ -351,7 +312,7 @@ class C {};
|
|
|
|
|
|
auto foo() -> C;
|
|
|
|
|
|
-// --- fail_todo_import_definition_value_return_type.carbon
|
|
|
+// --- import_definition_value_return_type.carbon
|
|
|
|
|
|
library "[[@TEST_NAME]]";
|
|
|
|
|
|
@@ -359,13 +320,6 @@ import Cpp library "definition_value_return_type.h";
|
|
|
|
|
|
fn F() {
|
|
|
//@dump-sem-ir-begin
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_value_return_type.carbon:[[@LINE+7]]:3: error: semantics TODO: `Unsupported: return type: class C` [SemanticsTodo]
|
|
|
- // CHECK:STDERR: Cpp.foo();
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR: fail_todo_import_definition_value_return_type.carbon:[[@LINE+4]]:3: note: in `Cpp` name lookup for `foo` [InCppNameLookup]
|
|
|
- // CHECK:STDERR: Cpp.foo();
|
|
|
- // CHECK:STDERR: ^~~~~~~
|
|
|
- // CHECK:STDERR:
|
|
|
Cpp.foo();
|
|
|
//@dump-sem-ir-end
|
|
|
}
|
|
|
@@ -428,115 +382,169 @@ fn F() {
|
|
|
//@dump-sem-ir-end
|
|
|
}
|
|
|
|
|
|
-// CHECK:STDOUT: --- fail_todo_import_decl_value_param_type.carbon
|
|
|
+// CHECK:STDOUT: --- import_definition_no_data_members_value_param_type.carbon
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: constants {
|
|
|
+// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete]
|
|
|
+// CHECK:STDOUT: %C: type = class_type @C [concrete]
|
|
|
// CHECK:STDOUT: %empty_struct_type: type = struct_type {} [concrete]
|
|
|
+// CHECK:STDOUT: %foo.type: type = fn_type @foo [concrete]
|
|
|
+// CHECK:STDOUT: %foo: %foo.type = struct_value () [concrete]
|
|
|
+// CHECK:STDOUT: %C.val: %C = struct_value () [concrete]
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: imports {
|
|
|
// CHECK:STDOUT: %Cpp: <namespace> = namespace file.%Cpp.import_cpp, [concrete] {
|
|
|
-// CHECK:STDOUT: .foo = <error>
|
|
|
+// CHECK:STDOUT: .foo = %foo.decl
|
|
|
+// CHECK:STDOUT: .C = %C.decl
|
|
|
// CHECK:STDOUT: import Cpp//...
|
|
|
// CHECK:STDOUT: }
|
|
|
-// CHECK:STDOUT: }
|
|
|
-// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: fn @F() {
|
|
|
-// CHECK:STDOUT: !entry:
|
|
|
-// CHECK:STDOUT: %Cpp.ref: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
-// CHECK:STDOUT: %foo.ref: <error> = name_ref foo, <error> [concrete = <error>]
|
|
|
-// CHECK:STDOUT: %.loc16: %empty_struct_type = struct_literal ()
|
|
|
-// CHECK:STDOUT: <elided>
|
|
|
-// CHECK:STDOUT: }
|
|
|
-// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: --- fail_todo_import_definition_no_data_members_value_param_type.carbon
|
|
|
-// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: constants {
|
|
|
-// CHECK:STDOUT: %empty_struct_type: type = struct_type {} [concrete]
|
|
|
-// CHECK:STDOUT: }
|
|
|
-// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: imports {
|
|
|
-// CHECK:STDOUT: %Cpp: <namespace> = namespace file.%Cpp.import_cpp, [concrete] {
|
|
|
-// CHECK:STDOUT: .foo = <error>
|
|
|
-// CHECK:STDOUT: import Cpp//...
|
|
|
+// CHECK:STDOUT: %C.decl: type = class_decl @C [concrete = constants.%C] {} {}
|
|
|
+// CHECK:STDOUT: %foo.decl: %foo.type = fn_decl @foo [concrete = constants.%foo] {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: } {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: fn @F() {
|
|
|
// CHECK:STDOUT: !entry:
|
|
|
// CHECK:STDOUT: %Cpp.ref: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
-// CHECK:STDOUT: %foo.ref: <error> = name_ref foo, <error> [concrete = <error>]
|
|
|
-// CHECK:STDOUT: %.loc15: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %foo.ref: %foo.type = name_ref foo, imports.%foo.decl [concrete = constants.%foo]
|
|
|
+// CHECK:STDOUT: %.loc8_12.1: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %.loc8_12.2: ref %C = temporary_storage
|
|
|
+// CHECK:STDOUT: %.loc8_12.3: init %C = class_init (), %.loc8_12.2 [concrete = constants.%C.val]
|
|
|
+// CHECK:STDOUT: %.loc8_12.4: ref %C = temporary %.loc8_12.2, %.loc8_12.3
|
|
|
+// CHECK:STDOUT: %.loc8_12.5: ref %C = converted %.loc8_12.1, %.loc8_12.4
|
|
|
+// CHECK:STDOUT: %.loc8_12.6: %C = bind_value %.loc8_12.5
|
|
|
+// CHECK:STDOUT: %foo.call: init %empty_tuple.type = call %foo.ref(%.loc8_12.6)
|
|
|
// CHECK:STDOUT: <elided>
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: --- fail_todo_import_definition_single_data_member_value_param_type.carbon
|
|
|
+// CHECK:STDOUT: --- import_definition_single_data_member_value_param_type.carbon
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: constants {
|
|
|
+// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete]
|
|
|
+// CHECK:STDOUT: %C: type = class_type @C [concrete]
|
|
|
// CHECK:STDOUT: %empty_struct_type: type = struct_type {} [concrete]
|
|
|
+// CHECK:STDOUT: %foo.type: type = fn_type @foo [concrete]
|
|
|
+// CHECK:STDOUT: %foo: %foo.type = struct_value () [concrete]
|
|
|
+// CHECK:STDOUT: %C.val: %C = struct_value () [concrete]
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: imports {
|
|
|
// CHECK:STDOUT: %Cpp: <namespace> = namespace file.%Cpp.import_cpp, [concrete] {
|
|
|
-// CHECK:STDOUT: .foo = <error>
|
|
|
+// CHECK:STDOUT: .foo = %foo.decl
|
|
|
+// CHECK:STDOUT: .C = %C.decl
|
|
|
// CHECK:STDOUT: import Cpp//...
|
|
|
// CHECK:STDOUT: }
|
|
|
+// CHECK:STDOUT: %C.decl: type = class_decl @C [concrete = constants.%C] {} {}
|
|
|
+// CHECK:STDOUT: %foo.decl: %foo.type = fn_decl @foo [concrete = constants.%foo] {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: } {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: fn @F() {
|
|
|
// CHECK:STDOUT: !entry:
|
|
|
// CHECK:STDOUT: %Cpp.ref: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
-// CHECK:STDOUT: %foo.ref: <error> = name_ref foo, <error> [concrete = <error>]
|
|
|
-// CHECK:STDOUT: %.loc15: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %foo.ref: %foo.type = name_ref foo, imports.%foo.decl [concrete = constants.%foo]
|
|
|
+// CHECK:STDOUT: %.loc8_12.1: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %.loc8_12.2: ref %C = temporary_storage
|
|
|
+// CHECK:STDOUT: %.loc8_12.3: init %C = class_init (), %.loc8_12.2 [concrete = constants.%C.val]
|
|
|
+// CHECK:STDOUT: %.loc8_12.4: ref %C = temporary %.loc8_12.2, %.loc8_12.3
|
|
|
+// CHECK:STDOUT: %.loc8_12.5: ref %C = converted %.loc8_12.1, %.loc8_12.4
|
|
|
+// CHECK:STDOUT: %.loc8_12.6: %C = bind_value %.loc8_12.5
|
|
|
+// CHECK:STDOUT: %foo.call: init %empty_tuple.type = call %foo.ref(%.loc8_12.6)
|
|
|
// CHECK:STDOUT: <elided>
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: --- fail_todo_import_definition_multiple_data_members_value_param_type.carbon
|
|
|
+// CHECK:STDOUT: --- import_definition_multiple_data_members_value_param_type.carbon
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: constants {
|
|
|
+// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete]
|
|
|
+// CHECK:STDOUT: %C: type = class_type @C [concrete]
|
|
|
// CHECK:STDOUT: %empty_struct_type: type = struct_type {} [concrete]
|
|
|
+// CHECK:STDOUT: %foo.type: type = fn_type @foo [concrete]
|
|
|
+// CHECK:STDOUT: %foo: %foo.type = struct_value () [concrete]
|
|
|
+// CHECK:STDOUT: %C.val: %C = struct_value () [concrete]
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: imports {
|
|
|
// CHECK:STDOUT: %Cpp: <namespace> = namespace file.%Cpp.import_cpp, [concrete] {
|
|
|
-// CHECK:STDOUT: .foo = <error>
|
|
|
+// CHECK:STDOUT: .foo = %foo.decl
|
|
|
+// CHECK:STDOUT: .C = %C.decl
|
|
|
// CHECK:STDOUT: import Cpp//...
|
|
|
// CHECK:STDOUT: }
|
|
|
+// CHECK:STDOUT: %C.decl: type = class_decl @C [concrete = constants.%C] {} {}
|
|
|
+// CHECK:STDOUT: %foo.decl: %foo.type = fn_decl @foo [concrete = constants.%foo] {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: } {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: fn @F() {
|
|
|
// CHECK:STDOUT: !entry:
|
|
|
// CHECK:STDOUT: %Cpp.ref: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
-// CHECK:STDOUT: %foo.ref: <error> = name_ref foo, <error> [concrete = <error>]
|
|
|
-// CHECK:STDOUT: %.loc15: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %foo.ref: %foo.type = name_ref foo, imports.%foo.decl [concrete = constants.%foo]
|
|
|
+// CHECK:STDOUT: %.loc8_12.1: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %.loc8_12.2: ref %C = temporary_storage
|
|
|
+// CHECK:STDOUT: %.loc8_12.3: init %C = class_init (), %.loc8_12.2 [concrete = constants.%C.val]
|
|
|
+// CHECK:STDOUT: %.loc8_12.4: ref %C = temporary %.loc8_12.2, %.loc8_12.3
|
|
|
+// CHECK:STDOUT: %.loc8_12.5: ref %C = converted %.loc8_12.1, %.loc8_12.4
|
|
|
+// CHECK:STDOUT: %.loc8_12.6: %C = bind_value %.loc8_12.5
|
|
|
+// CHECK:STDOUT: %foo.call: init %empty_tuple.type = call %foo.ref(%.loc8_12.6)
|
|
|
// CHECK:STDOUT: <elided>
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: --- fail_todo_import_definition_in_namespace_value_param_type.carbon
|
|
|
+// CHECK:STDOUT: --- import_definition_in_namespace_value_param_type.carbon
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: constants {
|
|
|
+// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete]
|
|
|
+// CHECK:STDOUT: %C: type = class_type @C [concrete]
|
|
|
// CHECK:STDOUT: %empty_struct_type: type = struct_type {} [concrete]
|
|
|
+// CHECK:STDOUT: %foo.type: type = fn_type @foo [concrete]
|
|
|
+// CHECK:STDOUT: %foo: %foo.type = struct_value () [concrete]
|
|
|
+// CHECK:STDOUT: %C.val: %C = struct_value () [concrete]
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: imports {
|
|
|
// CHECK:STDOUT: %Cpp: <namespace> = namespace file.%Cpp.import_cpp, [concrete] {
|
|
|
-// CHECK:STDOUT: .foo = <error>
|
|
|
+// CHECK:STDOUT: .foo = %foo.decl
|
|
|
// CHECK:STDOUT: import Cpp//...
|
|
|
// CHECK:STDOUT: }
|
|
|
+// CHECK:STDOUT: %foo.decl: %foo.type = fn_decl @foo [concrete = constants.%foo] {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: } {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: fn @F() {
|
|
|
// CHECK:STDOUT: !entry:
|
|
|
// CHECK:STDOUT: %Cpp.ref: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
-// CHECK:STDOUT: %foo.ref: <error> = name_ref foo, <error> [concrete = <error>]
|
|
|
-// CHECK:STDOUT: %.loc15: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %foo.ref: %foo.type = name_ref foo, imports.%foo.decl [concrete = constants.%foo]
|
|
|
+// CHECK:STDOUT: %.loc8_12.1: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %.loc8_12.2: ref %C = temporary_storage
|
|
|
+// CHECK:STDOUT: %.loc8_12.3: init %C = class_init (), %.loc8_12.2 [concrete = constants.%C.val]
|
|
|
+// CHECK:STDOUT: %.loc8_12.4: ref %C = temporary %.loc8_12.2, %.loc8_12.3
|
|
|
+// CHECK:STDOUT: %.loc8_12.5: ref %C = converted %.loc8_12.1, %.loc8_12.4
|
|
|
+// CHECK:STDOUT: %.loc8_12.6: %C = bind_value %.loc8_12.5
|
|
|
+// CHECK:STDOUT: %foo.call: init %empty_tuple.type = call %foo.ref(%.loc8_12.6)
|
|
|
// CHECK:STDOUT: <elided>
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: --- fail_todo_import_definition_in_relative_namespace_value_param_type.carbon
|
|
|
+// CHECK:STDOUT: --- import_definition_in_relative_namespace_value_param_type.carbon
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: constants {
|
|
|
+// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete]
|
|
|
+// CHECK:STDOUT: %C: type = class_type @C [concrete]
|
|
|
// CHECK:STDOUT: %empty_struct_type: type = struct_type {} [concrete]
|
|
|
+// CHECK:STDOUT: %foo.type: type = fn_type @foo [concrete]
|
|
|
+// CHECK:STDOUT: %foo: %foo.type = struct_value () [concrete]
|
|
|
+// CHECK:STDOUT: %C.val: %C = struct_value () [concrete]
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: imports {
|
|
|
@@ -545,21 +553,32 @@ fn F() {
|
|
|
// CHECK:STDOUT: import Cpp//...
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT: %N1: <namespace> = namespace [concrete] {
|
|
|
-// CHECK:STDOUT: .foo = <error>
|
|
|
+// CHECK:STDOUT: .foo = %foo.decl
|
|
|
// CHECK:STDOUT: import Cpp//...
|
|
|
// CHECK:STDOUT: }
|
|
|
+// CHECK:STDOUT: %foo.decl: %foo.type = fn_decl @foo [concrete = constants.%foo] {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: } {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: fn @F() {
|
|
|
// CHECK:STDOUT: !entry:
|
|
|
// CHECK:STDOUT: %Cpp.ref: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
// CHECK:STDOUT: %N1.ref: <namespace> = name_ref N1, imports.%N1 [concrete = imports.%N1]
|
|
|
-// CHECK:STDOUT: %foo.ref: <error> = name_ref foo, <error> [concrete = <error>]
|
|
|
-// CHECK:STDOUT: %.loc15: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %foo.ref: %foo.type = name_ref foo, imports.%foo.decl [concrete = constants.%foo]
|
|
|
+// CHECK:STDOUT: %.loc8_15.1: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %.loc8_15.2: ref %C = temporary_storage
|
|
|
+// CHECK:STDOUT: %.loc8_15.3: init %C = class_init (), %.loc8_15.2 [concrete = constants.%C.val]
|
|
|
+// CHECK:STDOUT: %.loc8_15.4: ref %C = temporary %.loc8_15.2, %.loc8_15.3
|
|
|
+// CHECK:STDOUT: %.loc8_15.5: ref %C = converted %.loc8_15.1, %.loc8_15.4
|
|
|
+// CHECK:STDOUT: %.loc8_15.6: %C = bind_value %.loc8_15.5
|
|
|
+// CHECK:STDOUT: %foo.call: init %empty_tuple.type = call %foo.ref(%.loc8_15.6)
|
|
|
// CHECK:STDOUT: <elided>
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: --- fail_todo_import_definition_and_static_method_call_before.carbon
|
|
|
+// CHECK:STDOUT: --- import_definition_and_static_method_call_before.carbon
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: constants {
|
|
|
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete]
|
|
|
@@ -567,16 +586,24 @@ fn F() {
|
|
|
// CHECK:STDOUT: %empty_struct_type: type = struct_type {} [concrete]
|
|
|
// CHECK:STDOUT: %bar.type: type = fn_type @bar [concrete]
|
|
|
// CHECK:STDOUT: %bar: %bar.type = struct_value () [concrete]
|
|
|
+// CHECK:STDOUT: %foo.type: type = fn_type @foo [concrete]
|
|
|
+// CHECK:STDOUT: %foo: %foo.type = struct_value () [concrete]
|
|
|
+// CHECK:STDOUT: %C.val: %C = struct_value () [concrete]
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: imports {
|
|
|
// CHECK:STDOUT: %Cpp: <namespace> = namespace file.%Cpp.import_cpp, [concrete] {
|
|
|
// CHECK:STDOUT: .C = %C.decl
|
|
|
-// CHECK:STDOUT: .foo = <error>
|
|
|
+// CHECK:STDOUT: .foo = %foo.decl
|
|
|
// CHECK:STDOUT: import Cpp//...
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT: %C.decl: type = class_decl @C [concrete = constants.%C] {} {}
|
|
|
// CHECK:STDOUT: %bar.decl: %bar.type = fn_decl @bar [concrete = constants.%bar] {} {}
|
|
|
+// CHECK:STDOUT: %foo.decl: %foo.type = fn_decl @foo [concrete = constants.%foo] {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: } {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: fn @F() {
|
|
|
@@ -586,39 +613,58 @@ fn F() {
|
|
|
// CHECK:STDOUT: %C.ref: type = name_ref C, imports.%C.decl [concrete = constants.%C]
|
|
|
// CHECK:STDOUT: %bar.ref: %bar.type = name_ref bar, imports.%bar.decl [concrete = constants.%bar]
|
|
|
// CHECK:STDOUT: %bar.call: init %empty_tuple.type = call %bar.ref()
|
|
|
-// CHECK:STDOUT: %Cpp.ref.loc16: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
-// CHECK:STDOUT: %foo.ref: <error> = name_ref foo, <error> [concrete = <error>]
|
|
|
-// CHECK:STDOUT: %.loc16: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %Cpp.ref.loc9: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
+// CHECK:STDOUT: %foo.ref: %foo.type = name_ref foo, imports.%foo.decl [concrete = constants.%foo]
|
|
|
+// CHECK:STDOUT: %.loc9_12.1: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %.loc9_12.2: ref %C = temporary_storage
|
|
|
+// CHECK:STDOUT: %.loc9_12.3: init %C = class_init (), %.loc9_12.2 [concrete = constants.%C.val]
|
|
|
+// CHECK:STDOUT: %.loc9_12.4: ref %C = temporary %.loc9_12.2, %.loc9_12.3
|
|
|
+// CHECK:STDOUT: %.loc9_12.5: ref %C = converted %.loc9_12.1, %.loc9_12.4
|
|
|
+// CHECK:STDOUT: %.loc9_12.6: %C = bind_value %.loc9_12.5
|
|
|
+// CHECK:STDOUT: %foo.call: init %empty_tuple.type = call %foo.ref(%.loc9_12.6)
|
|
|
// CHECK:STDOUT: <elided>
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: --- fail_todo_import_definition_and_static_method_call_after.carbon
|
|
|
+// CHECK:STDOUT: --- import_definition_and_static_method_call_after.carbon
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: constants {
|
|
|
// CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete]
|
|
|
-// CHECK:STDOUT: %empty_struct_type: type = struct_type {} [concrete]
|
|
|
// CHECK:STDOUT: %C: type = class_type @C [concrete]
|
|
|
+// CHECK:STDOUT: %empty_struct_type: type = struct_type {} [concrete]
|
|
|
+// CHECK:STDOUT: %foo.type: type = fn_type @foo [concrete]
|
|
|
+// CHECK:STDOUT: %foo: %foo.type = struct_value () [concrete]
|
|
|
+// CHECK:STDOUT: %C.val: %C = struct_value () [concrete]
|
|
|
// CHECK:STDOUT: %bar.type: type = fn_type @bar [concrete]
|
|
|
// CHECK:STDOUT: %bar: %bar.type = struct_value () [concrete]
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: imports {
|
|
|
// CHECK:STDOUT: %Cpp: <namespace> = namespace file.%Cpp.import_cpp, [concrete] {
|
|
|
-// CHECK:STDOUT: .foo = <error>
|
|
|
+// CHECK:STDOUT: .foo = %foo.decl
|
|
|
// CHECK:STDOUT: .C = %C.decl
|
|
|
// CHECK:STDOUT: import Cpp//...
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT: %C.decl: type = class_decl @C [concrete = constants.%C] {} {}
|
|
|
+// CHECK:STDOUT: %foo.decl: %foo.type = fn_decl @foo [concrete = constants.%foo] {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: } {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT: %bar.decl: %bar.type = fn_decl @bar [concrete = constants.%bar] {} {}
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: fn @F() {
|
|
|
// CHECK:STDOUT: !entry:
|
|
|
-// CHECK:STDOUT: %Cpp.ref.loc15: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
-// CHECK:STDOUT: %foo.ref: <error> = name_ref foo, <error> [concrete = <error>]
|
|
|
-// CHECK:STDOUT: %.loc15: %empty_struct_type = struct_literal ()
|
|
|
-// CHECK:STDOUT: %Cpp.ref.loc16: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
-// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: %Cpp.ref.loc8: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
+// CHECK:STDOUT: %foo.ref: %foo.type = name_ref foo, imports.%foo.decl [concrete = constants.%foo]
|
|
|
+// CHECK:STDOUT: %.loc8_12.1: %empty_struct_type = struct_literal ()
|
|
|
+// CHECK:STDOUT: %.loc8_12.2: ref %C = temporary_storage
|
|
|
+// CHECK:STDOUT: %.loc8_12.3: init %C = class_init (), %.loc8_12.2 [concrete = constants.%C.val]
|
|
|
+// CHECK:STDOUT: %.loc8_12.4: ref %C = temporary %.loc8_12.2, %.loc8_12.3
|
|
|
+// CHECK:STDOUT: %.loc8_12.5: ref %C = converted %.loc8_12.1, %.loc8_12.4
|
|
|
+// CHECK:STDOUT: %.loc8_12.6: %C = bind_value %.loc8_12.5
|
|
|
+// CHECK:STDOUT: %foo.call: init %empty_tuple.type = call %foo.ref(%.loc8_12.6)
|
|
|
+// CHECK:STDOUT: %Cpp.ref.loc9: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
// CHECK:STDOUT: %C.ref: type = name_ref C, imports.%C.decl [concrete = constants.%C]
|
|
|
// CHECK:STDOUT: %bar.ref: %bar.type = name_ref bar, imports.%bar.decl [concrete = constants.%bar]
|
|
|
// CHECK:STDOUT: %bar.call: init %empty_tuple.type = call %bar.ref()
|
|
|
@@ -638,11 +684,11 @@ fn F() {
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: fn @F(%s.param: <error>) {
|
|
|
+// CHECK:STDOUT: fn @F(%c.param: <error>) {
|
|
|
// CHECK:STDOUT: !entry:
|
|
|
// CHECK:STDOUT: %Cpp.ref.loc22: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
// CHECK:STDOUT: %foo.ref: <error> = name_ref foo, <error> [concrete = <error>]
|
|
|
-// CHECK:STDOUT: %s.ref: <error> = name_ref s, %s [concrete = <error>]
|
|
|
+// CHECK:STDOUT: %c.ref: <error> = name_ref c, %c [concrete = <error>]
|
|
|
// CHECK:STDOUT: <elided>
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
@@ -662,30 +708,43 @@ fn F() {
|
|
|
// CHECK:STDOUT: %C.decl: type = class_decl @C [concrete = constants.%C] {} {}
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: fn @F(%s.param: %ptr) {
|
|
|
+// CHECK:STDOUT: fn @F(%c.param: %ptr) {
|
|
|
// CHECK:STDOUT: !entry:
|
|
|
// CHECK:STDOUT: %Cpp.ref.loc15: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
// CHECK:STDOUT: %foo.ref: <error> = name_ref foo, <error> [concrete = <error>]
|
|
|
-// CHECK:STDOUT: %s.ref: %ptr = name_ref s, %s
|
|
|
+// CHECK:STDOUT: %c.ref: %ptr = name_ref c, %c
|
|
|
// CHECK:STDOUT: <elided>
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
-// CHECK:STDOUT: --- fail_todo_import_definition_value_return_type.carbon
|
|
|
+// CHECK:STDOUT: --- import_definition_value_return_type.carbon
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: constants {
|
|
|
+// CHECK:STDOUT: %C: type = class_type @C [concrete]
|
|
|
+// CHECK:STDOUT: %foo.type: type = fn_type @foo [concrete]
|
|
|
+// CHECK:STDOUT: %foo: %foo.type = struct_value () [concrete]
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: imports {
|
|
|
// CHECK:STDOUT: %Cpp: <namespace> = namespace file.%Cpp.import_cpp, [concrete] {
|
|
|
-// CHECK:STDOUT: .foo = <error>
|
|
|
+// CHECK:STDOUT: .foo = %foo.decl
|
|
|
+// CHECK:STDOUT: .C = %C.decl
|
|
|
// CHECK:STDOUT: import Cpp//...
|
|
|
// CHECK:STDOUT: }
|
|
|
+// CHECK:STDOUT: %C.decl: type = class_decl @C [concrete = constants.%C] {} {}
|
|
|
+// CHECK:STDOUT: %foo.decl: %foo.type = fn_decl @foo [concrete = constants.%foo] {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: } {
|
|
|
+// CHECK:STDOUT: <elided>
|
|
|
+// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|
|
|
// CHECK:STDOUT: fn @F() {
|
|
|
// CHECK:STDOUT: !entry:
|
|
|
// CHECK:STDOUT: %Cpp.ref: <namespace> = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp]
|
|
|
-// CHECK:STDOUT: %foo.ref: <error> = name_ref foo, <error> [concrete = <error>]
|
|
|
+// CHECK:STDOUT: %foo.ref: %foo.type = name_ref foo, imports.%foo.decl [concrete = constants.%foo]
|
|
|
+// CHECK:STDOUT: %.loc8_11.1: ref %C = temporary_storage
|
|
|
+// CHECK:STDOUT: %foo.call: init %C = call %foo.ref() to %.loc8_11.1
|
|
|
+// CHECK:STDOUT: %.loc8_11.2: ref %C = temporary %.loc8_11.1, %foo.call
|
|
|
// CHECK:STDOUT: <elided>
|
|
|
// CHECK:STDOUT: }
|
|
|
// CHECK:STDOUT:
|