| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- // Part of the Carbon Language project, under the Apache License v2.0 with LLVM
- // Exceptions. See /LICENSE for license information.
- // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
- //
- // AUTOUPDATE
- // TIP: To test this file alone, run:
- // TIP: bazel test //toolchain/testing:file_test --test_arg=--file_tests=toolchain/check/testdata/packages/fail_name_with_import_failure.carbon
- // TIP: To dump output, run:
- // TIP: bazel run //toolchain/testing:file_test -- --dump_output --file_tests=toolchain/check/testdata/packages/fail_name_with_import_failure.carbon
- // --- fail_implicit.impl.carbon
- // CHECK:STDERR: fail_implicit.impl.carbon:[[@LINE+4]]:6: error: corresponding API for 'Implicit' not found [LibraryApiNotFound]
- // CHECK:STDERR: impl package Implicit;
- // CHECK:STDERR: ^~~~~~~
- // CHECK:STDERR:
- impl package Implicit;
- var a: () = A();
- // CHECK:STDOUT: --- fail_implicit.impl.carbon
- // CHECK:STDOUT:
- // CHECK:STDOUT: constants {
- // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [template]
- // CHECK:STDOUT: }
- // CHECK:STDOUT:
- // CHECK:STDOUT: imports {
- // CHECK:STDOUT: %Core: <namespace> = namespace file.%Core.import, [template] {
- // CHECK:STDOUT: import Core//prelude
- // CHECK:STDOUT: import Core//prelude/...
- // CHECK:STDOUT: }
- // CHECK:STDOUT: }
- // CHECK:STDOUT:
- // CHECK:STDOUT: file {
- // CHECK:STDOUT: package: <namespace> = namespace [template] {
- // CHECK:STDOUT: .Core = imports.%Core
- // CHECK:STDOUT: .a = %a
- // CHECK:STDOUT: has_error
- // CHECK:STDOUT: }
- // CHECK:STDOUT: %default.import = import <none>
- // CHECK:STDOUT: %Core.import = import Core
- // CHECK:STDOUT: name_binding_decl {
- // CHECK:STDOUT: %a.patt: %empty_tuple.type = binding_pattern a
- // CHECK:STDOUT: %.loc8_1: %empty_tuple.type = var_pattern %a.patt
- // CHECK:STDOUT: }
- // CHECK:STDOUT: %a.var: ref %empty_tuple.type = var a
- // CHECK:STDOUT: %.loc8_9.1: type = splice_block %.loc8_9.3 [template = constants.%empty_tuple.type] {
- // CHECK:STDOUT: %.loc8_9.2: %empty_tuple.type = tuple_literal ()
- // CHECK:STDOUT: %.loc8_9.3: type = converted %.loc8_9.2, constants.%empty_tuple.type [template = constants.%empty_tuple.type]
- // CHECK:STDOUT: }
- // CHECK:STDOUT: %a: ref %empty_tuple.type = bind_name a, %a.var
- // CHECK:STDOUT: }
- // CHECK:STDOUT:
- // CHECK:STDOUT: fn @__global_init() {
- // CHECK:STDOUT: !entry:
- // CHECK:STDOUT: %A.ref: <error> = name_ref A, <error> [template = <error>]
- // CHECK:STDOUT: assign file.%a.var, <error>
- // CHECK:STDOUT: return
- // CHECK:STDOUT: }
- // CHECK:STDOUT:
|