// 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 // // INCLUDE-FILE: toolchain/testing/testdata/min_prelude/full.carbon // EXTRA-ARGS: --target=x86_64-pc-windows-msvc --clang-arg=-fno-PIE // // AUTOUPDATE // TIP: To test this file alone, run: // TIP: bazel test //toolchain/testing:file_test --test_arg=--file_tests=toolchain/check/testdata/interop/cpp/builtins.llp64.carbon // TIP: To dump output, run: // TIP: bazel run //toolchain/testing:file_test -- --dump_output --file_tests=toolchain/check/testdata/interop/cpp/builtins.llp64.carbon // --- long_long.carbon library "[[@TEST_NAME]]"; import Cpp; fn F() { //@dump-sem-ir-begin let cpp_long_long: Cpp.long_long = 1; let carbon_long_long: i64 = cpp_long_long; var a: array(f32, 1 as Cpp.long_long) = (1.0,); //@dump-sem-ir-end } // --- unsigned_long_long.carbon library "[[@TEST_NAME]]"; import Cpp; fn F() { //@dump-sem-ir-begin let cpp_unsigned_long_long: Cpp.unsigned_long_long = 1; let carbon_unsigned_long_long: u64 = cpp_unsigned_long_long; var a: array(f32, 1 as Cpp.unsigned_long_long) = (1.0,); //@dump-sem-ir-end } // --- long.carbon library "[[@TEST_NAME]]"; import Cpp inline ''' class LongResult {}; auto PassLong(long x) -> LongResult; class IntResult {}; auto PassLong(int x) -> IntResult; '''; fn F() { //@dump-sem-ir-begin let cpp_long: Cpp.long = 1; let cpp_long_result: Cpp.LongResult = Cpp.PassLong(cpp_long); let cpp_compat_long: Core.CppCompat.Long32 = cpp_long; let cpp_compat_long_result: Cpp.LongResult = Cpp.PassLong(cpp_compat_long); let carbon_i32: i32 = cpp_long; let carbon_i32_result: Cpp.IntResult = Cpp.PassLong(carbon_i32); var a: array(f32, 1 as Cpp.long) = (1.0,); //@dump-sem-ir-end } // --- unsigned_long.carbon library "[[@TEST_NAME]]"; import Cpp inline ''' class ULongResult {}; auto PassULong(unsigned long x) -> ULongResult; class UIntResult {}; auto PassULong(unsigned int x) -> UIntResult; '''; fn F() { //@dump-sem-ir-begin let cpp_unsigned_long: Cpp.unsigned_long = 1; let cpp_unsigned_long_result: Cpp.ULongResult = Cpp.PassULong(cpp_unsigned_long); let cpp_compat_ulong: Core.CppCompat.ULong32 = cpp_unsigned_long; let cpp_compat_ulong_result: Cpp.ULongResult = Cpp.PassULong(cpp_compat_ulong); let carbon_u32: u32 = cpp_unsigned_long; let carbon_u32_result: Cpp.UIntResult = Cpp.PassULong(carbon_u32); var a: array(f32, 1 as Cpp.unsigned_long) = (1.0,); //@dump-sem-ir-end } // CHECK:STDOUT: --- long_long.carbon // CHECK:STDOUT: // CHECK:STDOUT: constants { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete] // CHECK:STDOUT: %int_64: Core.IntLiteral = int_value 64 [concrete] // CHECK:STDOUT: %N: Core.IntLiteral = symbolic_binding N, 0 [symbolic] // CHECK:STDOUT: %i64: type = class_type @Int, @Int(%int_64) [concrete] // CHECK:STDOUT: %pattern_type.95b: type = pattern_type %i64 [concrete] // CHECK:STDOUT: %int_1.5b8: Core.IntLiteral = int_value 1 [concrete] // CHECK:STDOUT: %ImplicitAs.type.e50: type = facet_type <@ImplicitAs, @ImplicitAs(%i64)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.94e: type = fn_type @ImplicitAs.Convert, @ImplicitAs(%i64) [concrete] // CHECK:STDOUT: %To.fe9: Core.IntLiteral = symbolic_binding To, 0 [symbolic] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.412: type = fn_type @Core.IntLiteral.as.ImplicitAs.impl.Convert, @Core.IntLiteral.as.ImplicitAs.impl(%To.fe9) [symbolic] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.740: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.412 = struct_value () [symbolic] // CHECK:STDOUT: %ImplicitAs.type.7a9: type = facet_type <@ImplicitAs, @ImplicitAs(Core.IntLiteral)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.71e: type = fn_type @ImplicitAs.Convert, @ImplicitAs(Core.IntLiteral) [concrete] // CHECK:STDOUT: %From: Core.IntLiteral = symbolic_binding From, 0 [symbolic] // CHECK:STDOUT: %Int.as.ImplicitAs.impl.Convert.type.81d: type = fn_type @Int.as.ImplicitAs.impl.Convert, @Int.as.ImplicitAs.impl(%From) [symbolic] // CHECK:STDOUT: %Int.as.ImplicitAs.impl.Convert.e2a: %Int.as.ImplicitAs.impl.Convert.type.81d = struct_value () [symbolic] // CHECK:STDOUT: %ImplicitAs.impl_witness.281: = impl_witness imports.%ImplicitAs.impl_witness_table.99e, @Core.IntLiteral.as.ImplicitAs.impl(%int_64) [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.c10: type = fn_type @Core.IntLiteral.as.ImplicitAs.impl.Convert, @Core.IntLiteral.as.ImplicitAs.impl(%int_64) [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.f8e: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.c10 = struct_value () [concrete] // CHECK:STDOUT: %ImplicitAs.facet.934: %ImplicitAs.type.e50 = facet_value Core.IntLiteral, (%ImplicitAs.impl_witness.281) [concrete] // CHECK:STDOUT: %.c0a: type = fn_type_with_self_type %ImplicitAs.Convert.type.94e, %ImplicitAs.facet.934 [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.bound: = bound_method %int_1.5b8, %Core.IntLiteral.as.ImplicitAs.impl.Convert.f8e [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn: = specific_function %Core.IntLiteral.as.ImplicitAs.impl.Convert.f8e, @Core.IntLiteral.as.ImplicitAs.impl.Convert(%int_64) [concrete] // CHECK:STDOUT: %bound_method.7a7: = bound_method %int_1.5b8, %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete] // CHECK:STDOUT: %int_1.41a: %i64 = int_value 1 [concrete] // CHECK:STDOUT: %int_32: Core.IntLiteral = int_value 32 [concrete] // CHECK:STDOUT: %f32.97e: type = class_type @Float, @Float(%int_32) [concrete] // CHECK:STDOUT: %As.type.bbb: type = facet_type <@As, @As(%i64)> [concrete] // CHECK:STDOUT: %As.Convert.type.d57: type = fn_type @As.Convert, @As(%i64) [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.type.be4: type = fn_type @Core.IntLiteral.as.As.impl.Convert, @Core.IntLiteral.as.As.impl(%To.fe9) [symbolic] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.b5e: %Core.IntLiteral.as.As.impl.Convert.type.be4 = struct_value () [symbolic] // CHECK:STDOUT: %As.impl_witness.76d: = impl_witness imports.%As.impl_witness_table.de3, @Core.IntLiteral.as.As.impl(%int_64) [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.type.f64: type = fn_type @Core.IntLiteral.as.As.impl.Convert, @Core.IntLiteral.as.As.impl(%int_64) [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.607: %Core.IntLiteral.as.As.impl.Convert.type.f64 = struct_value () [concrete] // CHECK:STDOUT: %As.facet: %As.type.bbb = facet_value Core.IntLiteral, (%As.impl_witness.76d) [concrete] // CHECK:STDOUT: %.0d3: type = fn_type_with_self_type %As.Convert.type.d57, %As.facet [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.bound: = bound_method %int_1.5b8, %Core.IntLiteral.as.As.impl.Convert.607 [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.specific_fn: = specific_function %Core.IntLiteral.as.As.impl.Convert.607, @Core.IntLiteral.as.As.impl.Convert(%int_64) [concrete] // CHECK:STDOUT: %bound_method.a4b: = bound_method %int_1.5b8, %Core.IntLiteral.as.As.impl.Convert.specific_fn [concrete] // CHECK:STDOUT: %ImplicitAs.impl_witness.8f0: = impl_witness imports.%ImplicitAs.impl_witness_table.70d, @Int.as.ImplicitAs.impl(%int_64) [concrete] // CHECK:STDOUT: %Int.as.ImplicitAs.impl.Convert.type.660: type = fn_type @Int.as.ImplicitAs.impl.Convert, @Int.as.ImplicitAs.impl(%int_64) [concrete] // CHECK:STDOUT: %Int.as.ImplicitAs.impl.Convert.ed5: %Int.as.ImplicitAs.impl.Convert.type.660 = struct_value () [concrete] // CHECK:STDOUT: %ImplicitAs.facet.8b6: %ImplicitAs.type.7a9 = facet_value %i64, (%ImplicitAs.impl_witness.8f0) [concrete] // CHECK:STDOUT: %.9b5: type = fn_type_with_self_type %ImplicitAs.Convert.type.71e, %ImplicitAs.facet.8b6 [concrete] // CHECK:STDOUT: %Int.as.ImplicitAs.impl.Convert.bound: = bound_method %int_1.41a, %Int.as.ImplicitAs.impl.Convert.ed5 [concrete] // CHECK:STDOUT: %Int.as.ImplicitAs.impl.Convert.specific_fn: = specific_function %Int.as.ImplicitAs.impl.Convert.ed5, @Int.as.ImplicitAs.impl.Convert(%int_64) [concrete] // CHECK:STDOUT: %bound_method.73e: = bound_method %int_1.41a, %Int.as.ImplicitAs.impl.Convert.specific_fn [concrete] // CHECK:STDOUT: %array_type: type = array_type %int_1.5b8, %f32.97e [concrete] // CHECK:STDOUT: %pattern_type.b36: type = pattern_type %array_type [concrete] // CHECK:STDOUT: %float.674: Core.FloatLiteral = float_literal_value 10e-1 [concrete] // CHECK:STDOUT: %tuple.type: type = tuple_type (Core.FloatLiteral) [concrete] // CHECK:STDOUT: %tuple: %tuple.type = tuple_value (%float.674) [concrete] // CHECK:STDOUT: %int_0: Core.IntLiteral = int_value 0 [concrete] // CHECK:STDOUT: %ImplicitAs.type.921: type = facet_type <@ImplicitAs, @ImplicitAs(%f32.97e)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.b8c: type = fn_type @ImplicitAs.Convert, @ImplicitAs(%f32.97e) [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.fd4: type = fn_type @Core.FloatLiteral.as.ImplicitAs.impl.Convert, @Core.FloatLiteral.as.ImplicitAs.impl(%N) [symbolic] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.094: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.fd4 = struct_value () [symbolic] // CHECK:STDOUT: %ImplicitAs.impl_witness.d25: = impl_witness imports.%ImplicitAs.impl_witness_table.d6a, @Core.FloatLiteral.as.ImplicitAs.impl(%int_32) [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.85a: type = fn_type @Core.FloatLiteral.as.ImplicitAs.impl.Convert, @Core.FloatLiteral.as.ImplicitAs.impl(%int_32) [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.85a = struct_value () [concrete] // CHECK:STDOUT: %ImplicitAs.facet.9b7: %ImplicitAs.type.921 = facet_value Core.FloatLiteral, (%ImplicitAs.impl_witness.d25) [concrete] // CHECK:STDOUT: %.b83: type = fn_type_with_self_type %ImplicitAs.Convert.type.b8c, %ImplicitAs.facet.9b7 [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.bound: = bound_method %float.674, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8 [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.specific_fn: = specific_function %Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8, @Core.FloatLiteral.as.ImplicitAs.impl.Convert(%int_32) [concrete] // CHECK:STDOUT: %bound_method.1cf: = bound_method %float.674, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete] // CHECK:STDOUT: %float.e3b: %f32.97e = float_value 1 [concrete] // CHECK:STDOUT: %array: %array_type = tuple_value (%float.e3b) [concrete] // CHECK:STDOUT: %type_where: type = facet_type > [concrete] // CHECK:STDOUT: %facet_value: %type_where = facet_value %array_type, () [concrete] // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.type.fb2: type = fn_type @DestroyT.binding.as_type.as.Destroy.impl.Op, @DestroyT.binding.as_type.as.Destroy.impl(%facet_value) [concrete] // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.9ec: %DestroyT.binding.as_type.as.Destroy.impl.Op.type.fb2 = struct_value () [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { // CHECK:STDOUT: %Cpp: = namespace file.%Cpp.import_cpp, [concrete] { // CHECK:STDOUT: .long_long = @F.%i64.1 // CHECK:STDOUT: import Cpp//... // CHECK:STDOUT: } // CHECK:STDOUT: %Core.import_ref.3e1: @Core.IntLiteral.as.ImplicitAs.impl.%Core.IntLiteral.as.ImplicitAs.impl.Convert.type (%Core.IntLiteral.as.ImplicitAs.impl.Convert.type.412) = import_ref Core//prelude/types/int, loc{{\d+_\d+}}, loaded [symbolic = @Core.IntLiteral.as.ImplicitAs.impl.%Core.IntLiteral.as.ImplicitAs.impl.Convert (constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.740)] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.99e = impl_witness_table (%Core.import_ref.3e1), @Core.IntLiteral.as.ImplicitAs.impl [concrete] // CHECK:STDOUT: %Core.import_ref.9df: @Int.as.ImplicitAs.impl.%Int.as.ImplicitAs.impl.Convert.type (%Int.as.ImplicitAs.impl.Convert.type.81d) = import_ref Core//prelude/types/int, loc{{\d+_\d+}}, loaded [symbolic = @Int.as.ImplicitAs.impl.%Int.as.ImplicitAs.impl.Convert (constants.%Int.as.ImplicitAs.impl.Convert.e2a)] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.70d = impl_witness_table (%Core.import_ref.9df), @Int.as.ImplicitAs.impl [concrete] // CHECK:STDOUT: %Core.import_ref.ef2: @Core.IntLiteral.as.As.impl.%Core.IntLiteral.as.As.impl.Convert.type (%Core.IntLiteral.as.As.impl.Convert.type.be4) = import_ref Core//prelude/types/int, loc{{\d+_\d+}}, loaded [symbolic = @Core.IntLiteral.as.As.impl.%Core.IntLiteral.as.As.impl.Convert (constants.%Core.IntLiteral.as.As.impl.Convert.b5e)] // CHECK:STDOUT: %As.impl_witness_table.de3 = impl_witness_table (%Core.import_ref.ef2), @Core.IntLiteral.as.As.impl [concrete] // CHECK:STDOUT: %Core.import_ref.cf3: @Core.FloatLiteral.as.ImplicitAs.impl.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.type (%Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.fd4) = import_ref Core//prelude/types/float, loc{{\d+_\d+}}, loaded [symbolic = @Core.FloatLiteral.as.ImplicitAs.impl.%Core.FloatLiteral.as.ImplicitAs.impl.Convert (constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.094)] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.d6a = impl_witness_table (%Core.import_ref.cf3), @Core.FloatLiteral.as.ImplicitAs.impl [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: fn @F() { // CHECK:STDOUT: !entry: // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %cpp_long_long.patt: %pattern_type.95b = value_binding_pattern cpp_long_long [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %int_1.loc8: Core.IntLiteral = int_value 1 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %.loc8_25: type = splice_block %long_long.ref.loc8 [concrete = constants.%i64] { // CHECK:STDOUT: %Cpp.ref.loc8: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: // CHECK:STDOUT: %long_long.ref.loc8: type = name_ref long_long, %i64.1 [concrete = constants.%i64] // CHECK:STDOUT: } // CHECK:STDOUT: %impl.elem0.loc8: %.c0a = impl_witness_access constants.%ImplicitAs.impl_witness.281, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.f8e] // CHECK:STDOUT: %bound_method.loc8_38.1: = bound_method %int_1.loc8, %impl.elem0.loc8 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound] // CHECK:STDOUT: %specific_fn.loc8: = specific_function %impl.elem0.loc8, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_64) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn] // CHECK:STDOUT: %bound_method.loc8_38.2: = bound_method %int_1.loc8, %specific_fn.loc8 [concrete = constants.%bound_method.7a7] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call: init %i64 = call %bound_method.loc8_38.2(%int_1.loc8) [concrete = constants.%int_1.41a] // CHECK:STDOUT: %.loc8_38.1: %i64 = value_of_initializer %Core.IntLiteral.as.ImplicitAs.impl.Convert.call [concrete = constants.%int_1.41a] // CHECK:STDOUT: %.loc8_38.2: %i64 = converted %int_1.loc8, %.loc8_38.1 [concrete = constants.%int_1.41a] // CHECK:STDOUT: %cpp_long_long: %i64 = value_binding cpp_long_long, %.loc8_38.2 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %carbon_long_long.patt: %pattern_type.95b = value_binding_pattern carbon_long_long [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %cpp_long_long.ref: %i64 = name_ref cpp_long_long, %cpp_long_long // CHECK:STDOUT: %.loc9: type = splice_block %i64.loc9 [concrete = constants.%i64] { // CHECK:STDOUT: %int_64.loc9: Core.IntLiteral = int_value 64 [concrete = constants.%int_64] // CHECK:STDOUT: %i64.loc9: type = class_type @Int, @Int(constants.%int_64) [concrete = constants.%i64] // CHECK:STDOUT: } // CHECK:STDOUT: %carbon_long_long: %i64 = value_binding carbon_long_long, %cpp_long_long.ref // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %a.patt: %pattern_type.b36 = ref_binding_pattern a [concrete] // CHECK:STDOUT: %a.var_patt: %pattern_type.b36 = var_pattern %a.patt [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %a.var: ref %array_type = var %a.var_patt // CHECK:STDOUT: %float: Core.FloatLiteral = float_literal_value 10e-1 [concrete = constants.%float.674] // CHECK:STDOUT: %.loc11_48.1: %tuple.type = tuple_literal (%float) [concrete = constants.%tuple] // CHECK:STDOUT: %impl.elem0.loc11_48: %.b83 = impl_witness_access constants.%ImplicitAs.impl_witness.d25, element0 [concrete = constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8] // CHECK:STDOUT: %bound_method.loc11_48.1: = bound_method %float, %impl.elem0.loc11_48 [concrete = constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.bound] // CHECK:STDOUT: %specific_fn.loc11_48: = specific_function %impl.elem0.loc11_48, @Core.FloatLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.specific_fn] // CHECK:STDOUT: %bound_method.loc11_48.2: = bound_method %float, %specific_fn.loc11_48 [concrete = constants.%bound_method.1cf] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.call: init %f32.97e = call %bound_method.loc11_48.2(%float) [concrete = constants.%float.e3b] // CHECK:STDOUT: %.loc11_48.2: init %f32.97e = converted %float, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.call [concrete = constants.%float.e3b] // CHECK:STDOUT: %int_0: Core.IntLiteral = int_value 0 [concrete = constants.%int_0] // CHECK:STDOUT: %.loc11_48.3: ref %f32.97e = array_index %a.var, %int_0 // CHECK:STDOUT: %.loc11_48.4: init %f32.97e = initialize_from %.loc11_48.2 to %.loc11_48.3 [concrete = constants.%float.e3b] // CHECK:STDOUT: %.loc11_48.5: init %array_type = array_init (%.loc11_48.4) to %a.var [concrete = constants.%array] // CHECK:STDOUT: %.loc11_3: init %array_type = converted %.loc11_48.1, %.loc11_48.5 [concrete = constants.%array] // CHECK:STDOUT: assign %a.var, %.loc11_3 // CHECK:STDOUT: %.loc11_39: type = splice_block %array_type [concrete = constants.%array_type] { // CHECK:STDOUT: %int_32: Core.IntLiteral = int_value 32 [concrete = constants.%int_32] // CHECK:STDOUT: %f32: type = class_type @Float, @Float(constants.%int_32) [concrete = constants.%f32.97e] // CHECK:STDOUT: %int_1.loc11: Core.IntLiteral = int_value 1 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %Cpp.ref.loc11: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %long_long.ref.loc11: type = name_ref long_long, %i64.1 [concrete = constants.%i64] // CHECK:STDOUT: %impl.elem0.loc11_23.1: %.0d3 = impl_witness_access constants.%As.impl_witness.76d, element0 [concrete = constants.%Core.IntLiteral.as.As.impl.Convert.607] // CHECK:STDOUT: %bound_method.loc11_23.1: = bound_method %int_1.loc11, %impl.elem0.loc11_23.1 [concrete = constants.%Core.IntLiteral.as.As.impl.Convert.bound] // CHECK:STDOUT: %specific_fn.loc11_23.1: = specific_function %impl.elem0.loc11_23.1, @Core.IntLiteral.as.As.impl.Convert(constants.%int_64) [concrete = constants.%Core.IntLiteral.as.As.impl.Convert.specific_fn] // CHECK:STDOUT: %bound_method.loc11_23.2: = bound_method %int_1.loc11, %specific_fn.loc11_23.1 [concrete = constants.%bound_method.a4b] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.call: init %i64 = call %bound_method.loc11_23.2(%int_1.loc11) [concrete = constants.%int_1.41a] // CHECK:STDOUT: %.loc11_23.1: %i64 = value_of_initializer %Core.IntLiteral.as.As.impl.Convert.call [concrete = constants.%int_1.41a] // CHECK:STDOUT: %.loc11_23.2: %i64 = converted %int_1.loc11, %.loc11_23.1 [concrete = constants.%int_1.41a] // CHECK:STDOUT: %impl.elem0.loc11_23.2: %.9b5 = impl_witness_access constants.%ImplicitAs.impl_witness.8f0, element0 [concrete = constants.%Int.as.ImplicitAs.impl.Convert.ed5] // CHECK:STDOUT: %bound_method.loc11_23.3: = bound_method %.loc11_23.2, %impl.elem0.loc11_23.2 [concrete = constants.%Int.as.ImplicitAs.impl.Convert.bound] // CHECK:STDOUT: %specific_fn.loc11_23.2: = specific_function %impl.elem0.loc11_23.2, @Int.as.ImplicitAs.impl.Convert(constants.%int_64) [concrete = constants.%Int.as.ImplicitAs.impl.Convert.specific_fn] // CHECK:STDOUT: %bound_method.loc11_23.4: = bound_method %.loc11_23.2, %specific_fn.loc11_23.2 [concrete = constants.%bound_method.73e] // CHECK:STDOUT: %Int.as.ImplicitAs.impl.Convert.call: init Core.IntLiteral = call %bound_method.loc11_23.4(%.loc11_23.2) [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %.loc11_23.3: Core.IntLiteral = value_of_initializer %Int.as.ImplicitAs.impl.Convert.call [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %.loc11_23.4: Core.IntLiteral = converted %.loc11_23.2, %.loc11_23.3 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %array_type: type = array_type %.loc11_23.4, %f32 [concrete = constants.%array_type] // CHECK:STDOUT: } // CHECK:STDOUT: %a: ref %array_type = ref_binding a, %a.var // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.bound: = bound_method %a.var, constants.%DestroyT.binding.as_type.as.Destroy.impl.Op.9ec // CHECK:STDOUT: // CHECK:STDOUT: %bound_method.loc11_3: = bound_method %a.var, %DestroyT.binding.as_type.as.Destroy.impl.Op.specific_fn // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.call: init %empty_tuple.type = call %bound_method.loc11_3(%a.var) // CHECK:STDOUT: // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: --- unsigned_long_long.carbon // CHECK:STDOUT: // CHECK:STDOUT: constants { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete] // CHECK:STDOUT: %int_64: Core.IntLiteral = int_value 64 [concrete] // CHECK:STDOUT: %N: Core.IntLiteral = symbolic_binding N, 0 [symbolic] // CHECK:STDOUT: %u64: type = class_type @UInt, @UInt(%int_64) [concrete] // CHECK:STDOUT: %pattern_type.157: type = pattern_type %u64 [concrete] // CHECK:STDOUT: %int_1.5b8: Core.IntLiteral = int_value 1 [concrete] // CHECK:STDOUT: %ImplicitAs.type.b8f: type = facet_type <@ImplicitAs, @ImplicitAs(%u64)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.c65: type = fn_type @ImplicitAs.Convert, @ImplicitAs(%u64) [concrete] // CHECK:STDOUT: %To.fe9: Core.IntLiteral = symbolic_binding To, 0 [symbolic] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.5a9: type = fn_type @Core.IntLiteral.as.ImplicitAs.impl.Convert, @Core.IntLiteral.as.ImplicitAs.impl(%To.fe9) [symbolic] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.7a4: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.5a9 = struct_value () [symbolic] // CHECK:STDOUT: %ImplicitAs.type.7a9: type = facet_type <@ImplicitAs, @ImplicitAs(Core.IntLiteral)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.71e: type = fn_type @ImplicitAs.Convert, @ImplicitAs(Core.IntLiteral) [concrete] // CHECK:STDOUT: %From: Core.IntLiteral = symbolic_binding From, 0 [symbolic] // CHECK:STDOUT: %UInt.as.ImplicitAs.impl.Convert.type.eb8: type = fn_type @UInt.as.ImplicitAs.impl.Convert, @UInt.as.ImplicitAs.impl(%From) [symbolic] // CHECK:STDOUT: %UInt.as.ImplicitAs.impl.Convert.87c: %UInt.as.ImplicitAs.impl.Convert.type.eb8 = struct_value () [symbolic] // CHECK:STDOUT: %ImplicitAs.impl_witness.515: = impl_witness imports.%ImplicitAs.impl_witness_table.ef0, @Core.IntLiteral.as.ImplicitAs.impl(%int_64) [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.034: type = fn_type @Core.IntLiteral.as.ImplicitAs.impl.Convert, @Core.IntLiteral.as.ImplicitAs.impl(%int_64) [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.438: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.034 = struct_value () [concrete] // CHECK:STDOUT: %ImplicitAs.facet.0e8: %ImplicitAs.type.b8f = facet_value Core.IntLiteral, (%ImplicitAs.impl_witness.515) [concrete] // CHECK:STDOUT: %.7f2: type = fn_type_with_self_type %ImplicitAs.Convert.type.c65, %ImplicitAs.facet.0e8 [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.bound: = bound_method %int_1.5b8, %Core.IntLiteral.as.ImplicitAs.impl.Convert.438 [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn: = specific_function %Core.IntLiteral.as.ImplicitAs.impl.Convert.438, @Core.IntLiteral.as.ImplicitAs.impl.Convert(%int_64) [concrete] // CHECK:STDOUT: %bound_method.639: = bound_method %int_1.5b8, %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete] // CHECK:STDOUT: %int_1.f23: %u64 = int_value 1 [concrete] // CHECK:STDOUT: %int_32: Core.IntLiteral = int_value 32 [concrete] // CHECK:STDOUT: %f32.97e: type = class_type @Float, @Float(%int_32) [concrete] // CHECK:STDOUT: %As.type.465: type = facet_type <@As, @As(%u64)> [concrete] // CHECK:STDOUT: %As.Convert.type.7eb: type = fn_type @As.Convert, @As(%u64) [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.type.175: type = fn_type @Core.IntLiteral.as.As.impl.Convert, @Core.IntLiteral.as.As.impl(%To.fe9) [symbolic] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.0ab: %Core.IntLiteral.as.As.impl.Convert.type.175 = struct_value () [symbolic] // CHECK:STDOUT: %As.impl_witness.337: = impl_witness imports.%As.impl_witness_table.ee4, @Core.IntLiteral.as.As.impl(%int_64) [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.type.93d: type = fn_type @Core.IntLiteral.as.As.impl.Convert, @Core.IntLiteral.as.As.impl(%int_64) [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.7a7: %Core.IntLiteral.as.As.impl.Convert.type.93d = struct_value () [concrete] // CHECK:STDOUT: %As.facet: %As.type.465 = facet_value Core.IntLiteral, (%As.impl_witness.337) [concrete] // CHECK:STDOUT: %.cfa: type = fn_type_with_self_type %As.Convert.type.7eb, %As.facet [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.bound: = bound_method %int_1.5b8, %Core.IntLiteral.as.As.impl.Convert.7a7 [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.specific_fn: = specific_function %Core.IntLiteral.as.As.impl.Convert.7a7, @Core.IntLiteral.as.As.impl.Convert(%int_64) [concrete] // CHECK:STDOUT: %bound_method.33f: = bound_method %int_1.5b8, %Core.IntLiteral.as.As.impl.Convert.specific_fn [concrete] // CHECK:STDOUT: %ImplicitAs.impl_witness.2a0: = impl_witness imports.%ImplicitAs.impl_witness_table.3cf, @UInt.as.ImplicitAs.impl(%int_64) [concrete] // CHECK:STDOUT: %UInt.as.ImplicitAs.impl.Convert.type.1a4: type = fn_type @UInt.as.ImplicitAs.impl.Convert, @UInt.as.ImplicitAs.impl(%int_64) [concrete] // CHECK:STDOUT: %UInt.as.ImplicitAs.impl.Convert.77e: %UInt.as.ImplicitAs.impl.Convert.type.1a4 = struct_value () [concrete] // CHECK:STDOUT: %ImplicitAs.facet.f81: %ImplicitAs.type.7a9 = facet_value %u64, (%ImplicitAs.impl_witness.2a0) [concrete] // CHECK:STDOUT: %.1ff: type = fn_type_with_self_type %ImplicitAs.Convert.type.71e, %ImplicitAs.facet.f81 [concrete] // CHECK:STDOUT: %UInt.as.ImplicitAs.impl.Convert.bound: = bound_method %int_1.f23, %UInt.as.ImplicitAs.impl.Convert.77e [concrete] // CHECK:STDOUT: %UInt.as.ImplicitAs.impl.Convert.specific_fn: = specific_function %UInt.as.ImplicitAs.impl.Convert.77e, @UInt.as.ImplicitAs.impl.Convert(%int_64) [concrete] // CHECK:STDOUT: %bound_method.c66: = bound_method %int_1.f23, %UInt.as.ImplicitAs.impl.Convert.specific_fn [concrete] // CHECK:STDOUT: %array_type: type = array_type %int_1.5b8, %f32.97e [concrete] // CHECK:STDOUT: %pattern_type.b36: type = pattern_type %array_type [concrete] // CHECK:STDOUT: %float.674: Core.FloatLiteral = float_literal_value 10e-1 [concrete] // CHECK:STDOUT: %tuple.type: type = tuple_type (Core.FloatLiteral) [concrete] // CHECK:STDOUT: %tuple: %tuple.type = tuple_value (%float.674) [concrete] // CHECK:STDOUT: %int_0: Core.IntLiteral = int_value 0 [concrete] // CHECK:STDOUT: %ImplicitAs.type.921: type = facet_type <@ImplicitAs, @ImplicitAs(%f32.97e)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.b8c: type = fn_type @ImplicitAs.Convert, @ImplicitAs(%f32.97e) [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.fd4: type = fn_type @Core.FloatLiteral.as.ImplicitAs.impl.Convert, @Core.FloatLiteral.as.ImplicitAs.impl(%N) [symbolic] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.094: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.fd4 = struct_value () [symbolic] // CHECK:STDOUT: %ImplicitAs.impl_witness.d25: = impl_witness imports.%ImplicitAs.impl_witness_table.d6a, @Core.FloatLiteral.as.ImplicitAs.impl(%int_32) [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.85a: type = fn_type @Core.FloatLiteral.as.ImplicitAs.impl.Convert, @Core.FloatLiteral.as.ImplicitAs.impl(%int_32) [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.85a = struct_value () [concrete] // CHECK:STDOUT: %ImplicitAs.facet.9b7: %ImplicitAs.type.921 = facet_value Core.FloatLiteral, (%ImplicitAs.impl_witness.d25) [concrete] // CHECK:STDOUT: %.b83: type = fn_type_with_self_type %ImplicitAs.Convert.type.b8c, %ImplicitAs.facet.9b7 [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.bound: = bound_method %float.674, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8 [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.specific_fn: = specific_function %Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8, @Core.FloatLiteral.as.ImplicitAs.impl.Convert(%int_32) [concrete] // CHECK:STDOUT: %bound_method.1cf: = bound_method %float.674, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete] // CHECK:STDOUT: %float.e3b: %f32.97e = float_value 1 [concrete] // CHECK:STDOUT: %array: %array_type = tuple_value (%float.e3b) [concrete] // CHECK:STDOUT: %type_where: type = facet_type > [concrete] // CHECK:STDOUT: %facet_value: %type_where = facet_value %array_type, () [concrete] // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.type.fb2: type = fn_type @DestroyT.binding.as_type.as.Destroy.impl.Op, @DestroyT.binding.as_type.as.Destroy.impl(%facet_value) [concrete] // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.9ec: %DestroyT.binding.as_type.as.Destroy.impl.Op.type.fb2 = struct_value () [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { // CHECK:STDOUT: %Cpp: = namespace file.%Cpp.import_cpp, [concrete] { // CHECK:STDOUT: .unsigned_long_long = @F.%u64.1 // CHECK:STDOUT: import Cpp//... // CHECK:STDOUT: } // CHECK:STDOUT: %Core.import_ref.d80: @Core.IntLiteral.as.ImplicitAs.impl.%Core.IntLiteral.as.ImplicitAs.impl.Convert.type (%Core.IntLiteral.as.ImplicitAs.impl.Convert.type.5a9) = import_ref Core//prelude/types/uint, loc{{\d+_\d+}}, loaded [symbolic = @Core.IntLiteral.as.ImplicitAs.impl.%Core.IntLiteral.as.ImplicitAs.impl.Convert (constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.7a4)] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.ef0 = impl_witness_table (%Core.import_ref.d80), @Core.IntLiteral.as.ImplicitAs.impl [concrete] // CHECK:STDOUT: %Core.import_ref.ce7: @UInt.as.ImplicitAs.impl.%UInt.as.ImplicitAs.impl.Convert.type (%UInt.as.ImplicitAs.impl.Convert.type.eb8) = import_ref Core//prelude/types/uint, loc{{\d+_\d+}}, loaded [symbolic = @UInt.as.ImplicitAs.impl.%UInt.as.ImplicitAs.impl.Convert (constants.%UInt.as.ImplicitAs.impl.Convert.87c)] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.3cf = impl_witness_table (%Core.import_ref.ce7), @UInt.as.ImplicitAs.impl [concrete] // CHECK:STDOUT: %Core.import_ref.963: @Core.IntLiteral.as.As.impl.%Core.IntLiteral.as.As.impl.Convert.type (%Core.IntLiteral.as.As.impl.Convert.type.175) = import_ref Core//prelude/types/uint, loc{{\d+_\d+}}, loaded [symbolic = @Core.IntLiteral.as.As.impl.%Core.IntLiteral.as.As.impl.Convert (constants.%Core.IntLiteral.as.As.impl.Convert.0ab)] // CHECK:STDOUT: %As.impl_witness_table.ee4 = impl_witness_table (%Core.import_ref.963), @Core.IntLiteral.as.As.impl [concrete] // CHECK:STDOUT: %Core.import_ref.cf3: @Core.FloatLiteral.as.ImplicitAs.impl.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.type (%Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.fd4) = import_ref Core//prelude/types/float, loc{{\d+_\d+}}, loaded [symbolic = @Core.FloatLiteral.as.ImplicitAs.impl.%Core.FloatLiteral.as.ImplicitAs.impl.Convert (constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.094)] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.d6a = impl_witness_table (%Core.import_ref.cf3), @Core.FloatLiteral.as.ImplicitAs.impl [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: fn @F() { // CHECK:STDOUT: !entry: // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %cpp_unsigned_long_long.patt: %pattern_type.157 = value_binding_pattern cpp_unsigned_long_long [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %int_1.loc8: Core.IntLiteral = int_value 1 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %.loc8_34: type = splice_block %unsigned_long_long.ref.loc8 [concrete = constants.%u64] { // CHECK:STDOUT: %Cpp.ref.loc8: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: // CHECK:STDOUT: %unsigned_long_long.ref.loc8: type = name_ref unsigned_long_long, %u64.1 [concrete = constants.%u64] // CHECK:STDOUT: } // CHECK:STDOUT: %impl.elem0.loc8: %.7f2 = impl_witness_access constants.%ImplicitAs.impl_witness.515, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.438] // CHECK:STDOUT: %bound_method.loc8_56.1: = bound_method %int_1.loc8, %impl.elem0.loc8 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound] // CHECK:STDOUT: %specific_fn.loc8: = specific_function %impl.elem0.loc8, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_64) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn] // CHECK:STDOUT: %bound_method.loc8_56.2: = bound_method %int_1.loc8, %specific_fn.loc8 [concrete = constants.%bound_method.639] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call: init %u64 = call %bound_method.loc8_56.2(%int_1.loc8) [concrete = constants.%int_1.f23] // CHECK:STDOUT: %.loc8_56.1: %u64 = value_of_initializer %Core.IntLiteral.as.ImplicitAs.impl.Convert.call [concrete = constants.%int_1.f23] // CHECK:STDOUT: %.loc8_56.2: %u64 = converted %int_1.loc8, %.loc8_56.1 [concrete = constants.%int_1.f23] // CHECK:STDOUT: %cpp_unsigned_long_long: %u64 = value_binding cpp_unsigned_long_long, %.loc8_56.2 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %carbon_unsigned_long_long.patt: %pattern_type.157 = value_binding_pattern carbon_unsigned_long_long [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %cpp_unsigned_long_long.ref: %u64 = name_ref cpp_unsigned_long_long, %cpp_unsigned_long_long // CHECK:STDOUT: %.loc9: type = splice_block %u64.loc9 [concrete = constants.%u64] { // CHECK:STDOUT: %int_64.loc9: Core.IntLiteral = int_value 64 [concrete = constants.%int_64] // CHECK:STDOUT: %u64.loc9: type = class_type @UInt, @UInt(constants.%int_64) [concrete = constants.%u64] // CHECK:STDOUT: } // CHECK:STDOUT: %carbon_unsigned_long_long: %u64 = value_binding carbon_unsigned_long_long, %cpp_unsigned_long_long.ref // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %a.patt: %pattern_type.b36 = ref_binding_pattern a [concrete] // CHECK:STDOUT: %a.var_patt: %pattern_type.b36 = var_pattern %a.patt [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %a.var: ref %array_type = var %a.var_patt // CHECK:STDOUT: %float: Core.FloatLiteral = float_literal_value 10e-1 [concrete = constants.%float.674] // CHECK:STDOUT: %.loc11_57.1: %tuple.type = tuple_literal (%float) [concrete = constants.%tuple] // CHECK:STDOUT: %impl.elem0.loc11_57: %.b83 = impl_witness_access constants.%ImplicitAs.impl_witness.d25, element0 [concrete = constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8] // CHECK:STDOUT: %bound_method.loc11_57.1: = bound_method %float, %impl.elem0.loc11_57 [concrete = constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.bound] // CHECK:STDOUT: %specific_fn.loc11_57: = specific_function %impl.elem0.loc11_57, @Core.FloatLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.specific_fn] // CHECK:STDOUT: %bound_method.loc11_57.2: = bound_method %float, %specific_fn.loc11_57 [concrete = constants.%bound_method.1cf] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.call: init %f32.97e = call %bound_method.loc11_57.2(%float) [concrete = constants.%float.e3b] // CHECK:STDOUT: %.loc11_57.2: init %f32.97e = converted %float, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.call [concrete = constants.%float.e3b] // CHECK:STDOUT: %int_0: Core.IntLiteral = int_value 0 [concrete = constants.%int_0] // CHECK:STDOUT: %.loc11_57.3: ref %f32.97e = array_index %a.var, %int_0 // CHECK:STDOUT: %.loc11_57.4: init %f32.97e = initialize_from %.loc11_57.2 to %.loc11_57.3 [concrete = constants.%float.e3b] // CHECK:STDOUT: %.loc11_57.5: init %array_type = array_init (%.loc11_57.4) to %a.var [concrete = constants.%array] // CHECK:STDOUT: %.loc11_3: init %array_type = converted %.loc11_57.1, %.loc11_57.5 [concrete = constants.%array] // CHECK:STDOUT: assign %a.var, %.loc11_3 // CHECK:STDOUT: %.loc11_48: type = splice_block %array_type [concrete = constants.%array_type] { // CHECK:STDOUT: %int_32: Core.IntLiteral = int_value 32 [concrete = constants.%int_32] // CHECK:STDOUT: %f32: type = class_type @Float, @Float(constants.%int_32) [concrete = constants.%f32.97e] // CHECK:STDOUT: %int_1.loc11: Core.IntLiteral = int_value 1 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %Cpp.ref.loc11: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %unsigned_long_long.ref.loc11: type = name_ref unsigned_long_long, %u64.1 [concrete = constants.%u64] // CHECK:STDOUT: %impl.elem0.loc11_23.1: %.cfa = impl_witness_access constants.%As.impl_witness.337, element0 [concrete = constants.%Core.IntLiteral.as.As.impl.Convert.7a7] // CHECK:STDOUT: %bound_method.loc11_23.1: = bound_method %int_1.loc11, %impl.elem0.loc11_23.1 [concrete = constants.%Core.IntLiteral.as.As.impl.Convert.bound] // CHECK:STDOUT: %specific_fn.loc11_23.1: = specific_function %impl.elem0.loc11_23.1, @Core.IntLiteral.as.As.impl.Convert(constants.%int_64) [concrete = constants.%Core.IntLiteral.as.As.impl.Convert.specific_fn] // CHECK:STDOUT: %bound_method.loc11_23.2: = bound_method %int_1.loc11, %specific_fn.loc11_23.1 [concrete = constants.%bound_method.33f] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.call: init %u64 = call %bound_method.loc11_23.2(%int_1.loc11) [concrete = constants.%int_1.f23] // CHECK:STDOUT: %.loc11_23.1: %u64 = value_of_initializer %Core.IntLiteral.as.As.impl.Convert.call [concrete = constants.%int_1.f23] // CHECK:STDOUT: %.loc11_23.2: %u64 = converted %int_1.loc11, %.loc11_23.1 [concrete = constants.%int_1.f23] // CHECK:STDOUT: %impl.elem0.loc11_23.2: %.1ff = impl_witness_access constants.%ImplicitAs.impl_witness.2a0, element0 [concrete = constants.%UInt.as.ImplicitAs.impl.Convert.77e] // CHECK:STDOUT: %bound_method.loc11_23.3: = bound_method %.loc11_23.2, %impl.elem0.loc11_23.2 [concrete = constants.%UInt.as.ImplicitAs.impl.Convert.bound] // CHECK:STDOUT: %specific_fn.loc11_23.2: = specific_function %impl.elem0.loc11_23.2, @UInt.as.ImplicitAs.impl.Convert(constants.%int_64) [concrete = constants.%UInt.as.ImplicitAs.impl.Convert.specific_fn] // CHECK:STDOUT: %bound_method.loc11_23.4: = bound_method %.loc11_23.2, %specific_fn.loc11_23.2 [concrete = constants.%bound_method.c66] // CHECK:STDOUT: %UInt.as.ImplicitAs.impl.Convert.call: init Core.IntLiteral = call %bound_method.loc11_23.4(%.loc11_23.2) [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %.loc11_23.3: Core.IntLiteral = value_of_initializer %UInt.as.ImplicitAs.impl.Convert.call [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %.loc11_23.4: Core.IntLiteral = converted %.loc11_23.2, %.loc11_23.3 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %array_type: type = array_type %.loc11_23.4, %f32 [concrete = constants.%array_type] // CHECK:STDOUT: } // CHECK:STDOUT: %a: ref %array_type = ref_binding a, %a.var // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.bound: = bound_method %a.var, constants.%DestroyT.binding.as_type.as.Destroy.impl.Op.9ec // CHECK:STDOUT: // CHECK:STDOUT: %bound_method.loc11_3: = bound_method %a.var, %DestroyT.binding.as_type.as.Destroy.impl.Op.specific_fn // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.call: init %empty_tuple.type = call %bound_method.loc11_3(%a.var) // CHECK:STDOUT: // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: --- long.carbon // CHECK:STDOUT: // CHECK:STDOUT: constants { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete] // CHECK:STDOUT: %Cpp.long: type = class_type @Long32 [concrete] // CHECK:STDOUT: %int_32: Core.IntLiteral = int_value 32 [concrete] // CHECK:STDOUT: %Int.type: type = generic_class_type @Int [concrete] // CHECK:STDOUT: %Int.generic: %Int.type = struct_value () [concrete] // CHECK:STDOUT: %N: Core.IntLiteral = symbolic_binding N, 0 [symbolic] // CHECK:STDOUT: %i32: type = class_type @Int, @Int(%int_32) [concrete] // CHECK:STDOUT: %pattern_type.68c: type = pattern_type %Cpp.long [concrete] // CHECK:STDOUT: %int_1.5b8: Core.IntLiteral = int_value 1 [concrete] // CHECK:STDOUT: %ImplicitAs.type.cc7: type = generic_interface_type @ImplicitAs [concrete] // CHECK:STDOUT: %ImplicitAs.generic: %ImplicitAs.type.cc7 = struct_value () [concrete] // CHECK:STDOUT: %ImplicitAs.type.c65: type = facet_type <@ImplicitAs, @ImplicitAs(%Cpp.long)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.4c2: type = fn_type @ImplicitAs.Convert, @ImplicitAs(%Cpp.long) [concrete] // CHECK:STDOUT: %ImplicitAs.type.7a9: type = facet_type <@ImplicitAs, @ImplicitAs(Core.IntLiteral)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.71e: type = fn_type @ImplicitAs.Convert, @ImplicitAs(Core.IntLiteral) [concrete] // CHECK:STDOUT: %ImplicitAs.type.d14: type = facet_type <@ImplicitAs, @ImplicitAs(%i32)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.1b6: type = fn_type @ImplicitAs.Convert, @ImplicitAs(%i32) [concrete] // CHECK:STDOUT: %ImplicitAs.impl_witness.ab8: = impl_witness imports.%ImplicitAs.impl_witness_table.dc9 [concrete] // CHECK:STDOUT: %ImplicitAs.facet.a66: %ImplicitAs.type.c65 = facet_value Core.IntLiteral, (%ImplicitAs.impl_witness.ab8) [concrete] // CHECK:STDOUT: %.e52: type = fn_type_with_self_type %ImplicitAs.Convert.type.4c2, %ImplicitAs.facet.a66 [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.2be: type = fn_type @Core.IntLiteral.as.ImplicitAs.impl.Convert.1 [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.a1f: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.2be = struct_value () [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.bound: = bound_method %int_1.5b8, %Core.IntLiteral.as.ImplicitAs.impl.Convert.a1f [concrete] // CHECK:STDOUT: %int_1.5a4: %Cpp.long = int_value 1 [concrete] // CHECK:STDOUT: %LongResult: type = class_type @LongResult [concrete] // CHECK:STDOUT: %pattern_type.cd9: type = pattern_type %LongResult [concrete] // CHECK:STDOUT: %PassLong.cpp_overload_set.type: type = cpp_overload_set_type @PassLong.cpp_overload_set [concrete] // CHECK:STDOUT: %PassLong.cpp_overload_set.value: %PassLong.cpp_overload_set.type = cpp_overload_set_value @PassLong.cpp_overload_set [concrete] // CHECK:STDOUT: %ptr.305: type = ptr_type %LongResult [concrete] // CHECK:STDOUT: %PassLong__carbon_thunk.type.9d9430.1: type = fn_type @PassLong__carbon_thunk.1 [concrete] // CHECK:STDOUT: %PassLong__carbon_thunk.58a8f3.1: %PassLong__carbon_thunk.type.9d9430.1 = struct_value () [concrete] // CHECK:STDOUT: %pattern_type.7ce: type = pattern_type %i32 [concrete] // CHECK:STDOUT: %ImplicitAs.impl_witness.c39: = impl_witness imports.%ImplicitAs.impl_witness_table.90c [concrete] // CHECK:STDOUT: %ImplicitAs.facet.a39: %ImplicitAs.type.d14 = facet_value %Cpp.long, (%ImplicitAs.impl_witness.c39) [concrete] // CHECK:STDOUT: %.261: type = fn_type_with_self_type %ImplicitAs.Convert.type.1b6, %ImplicitAs.facet.a39 [concrete] // CHECK:STDOUT: %Cpp.long.as.ImplicitAs.impl.Convert.type.395: type = fn_type @Cpp.long.as.ImplicitAs.impl.Convert.1 [concrete] // CHECK:STDOUT: %Cpp.long.as.ImplicitAs.impl.Convert.e43: %Cpp.long.as.ImplicitAs.impl.Convert.type.395 = struct_value () [concrete] // CHECK:STDOUT: %IntResult: type = class_type @IntResult [concrete] // CHECK:STDOUT: %pattern_type.454: type = pattern_type %IntResult [concrete] // CHECK:STDOUT: %ptr.3cb: type = ptr_type %IntResult [concrete] // CHECK:STDOUT: %PassLong__carbon_thunk.type.9d9430.2: type = fn_type @PassLong__carbon_thunk.2 [concrete] // CHECK:STDOUT: %PassLong__carbon_thunk.58a8f3.2: %PassLong__carbon_thunk.type.9d9430.2 = struct_value () [concrete] // CHECK:STDOUT: %Float.type: type = generic_class_type @Float [concrete] // CHECK:STDOUT: %Float.generic: %Float.type = struct_value () [concrete] // CHECK:STDOUT: %f32.97e: type = class_type @Float, @Float(%int_32) [concrete] // CHECK:STDOUT: %As.type.90f: type = generic_interface_type @As [concrete] // CHECK:STDOUT: %As.generic: %As.type.90f = struct_value () [concrete] // CHECK:STDOUT: %As.type.c94: type = facet_type <@As, @As(%Cpp.long)> [concrete] // CHECK:STDOUT: %As.Convert.type.229: type = fn_type @As.Convert, @As(%Cpp.long) [concrete] // CHECK:STDOUT: %As.impl_witness: = impl_witness imports.%As.impl_witness_table [concrete] // CHECK:STDOUT: %As.facet: %As.type.c94 = facet_value Core.IntLiteral, (%As.impl_witness) [concrete] // CHECK:STDOUT: %.751: type = fn_type_with_self_type %As.Convert.type.229, %As.facet [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.type: type = fn_type @Core.IntLiteral.as.As.impl.Convert [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert: %Core.IntLiteral.as.As.impl.Convert.type = struct_value () [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.bound: = bound_method %int_1.5b8, %Core.IntLiteral.as.As.impl.Convert [concrete] // CHECK:STDOUT: %ImplicitAs.impl_witness.1e0: = impl_witness imports.%ImplicitAs.impl_witness_table.d3d [concrete] // CHECK:STDOUT: %ImplicitAs.facet.d01: %ImplicitAs.type.7a9 = facet_value %Cpp.long, (%ImplicitAs.impl_witness.1e0) [concrete] // CHECK:STDOUT: %.907: type = fn_type_with_self_type %ImplicitAs.Convert.type.71e, %ImplicitAs.facet.d01 [concrete] // CHECK:STDOUT: %Cpp.long.as.ImplicitAs.impl.Convert.type.eba: type = fn_type @Cpp.long.as.ImplicitAs.impl.Convert.2 [concrete] // CHECK:STDOUT: %Cpp.long.as.ImplicitAs.impl.Convert.082: %Cpp.long.as.ImplicitAs.impl.Convert.type.eba = struct_value () [concrete] // CHECK:STDOUT: %Cpp.long.as.ImplicitAs.impl.Convert.bound: = bound_method %int_1.5a4, %Cpp.long.as.ImplicitAs.impl.Convert.082 [concrete] // CHECK:STDOUT: %array_type: type = array_type %int_1.5b8, %f32.97e [concrete] // CHECK:STDOUT: %pattern_type.b36: type = pattern_type %array_type [concrete] // CHECK:STDOUT: %float.674: Core.FloatLiteral = float_literal_value 10e-1 [concrete] // CHECK:STDOUT: %tuple.type: type = tuple_type (Core.FloatLiteral) [concrete] // CHECK:STDOUT: %tuple: %tuple.type = tuple_value (%float.674) [concrete] // CHECK:STDOUT: %int_0: Core.IntLiteral = int_value 0 [concrete] // CHECK:STDOUT: %ImplicitAs.type.921: type = facet_type <@ImplicitAs, @ImplicitAs(%f32.97e)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.b8c: type = fn_type @ImplicitAs.Convert, @ImplicitAs(%f32.97e) [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.fd4: type = fn_type @Core.FloatLiteral.as.ImplicitAs.impl.Convert, @Core.FloatLiteral.as.ImplicitAs.impl(%N) [symbolic] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.094: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.fd4 = struct_value () [symbolic] // CHECK:STDOUT: %ImplicitAs.impl_witness.d25: = impl_witness imports.%ImplicitAs.impl_witness_table.d6a, @Core.FloatLiteral.as.ImplicitAs.impl(%int_32) [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.85a: type = fn_type @Core.FloatLiteral.as.ImplicitAs.impl.Convert, @Core.FloatLiteral.as.ImplicitAs.impl(%int_32) [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.85a = struct_value () [concrete] // CHECK:STDOUT: %ImplicitAs.facet.9b7: %ImplicitAs.type.921 = facet_value Core.FloatLiteral, (%ImplicitAs.impl_witness.d25) [concrete] // CHECK:STDOUT: %.b83: type = fn_type_with_self_type %ImplicitAs.Convert.type.b8c, %ImplicitAs.facet.9b7 [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.bound: = bound_method %float.674, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8 [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.specific_fn: = specific_function %Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8, @Core.FloatLiteral.as.ImplicitAs.impl.Convert(%int_32) [concrete] // CHECK:STDOUT: %bound_method: = bound_method %float.674, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete] // CHECK:STDOUT: %float.e3b: %f32.97e = float_value 1 [concrete] // CHECK:STDOUT: %array: %array_type = tuple_value (%float.e3b) [concrete] // CHECK:STDOUT: %Destroy.type: type = facet_type <@Destroy> [concrete] // CHECK:STDOUT: %type_where: type = facet_type > [concrete] // CHECK:STDOUT: %facet_value.cee: %type_where = facet_value %array_type, () [concrete] // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.type.fb2: type = fn_type @DestroyT.binding.as_type.as.Destroy.impl.Op, @DestroyT.binding.as_type.as.Destroy.impl(%facet_value.cee) [concrete] // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.9ec: %DestroyT.binding.as_type.as.Destroy.impl.Op.type.fb2 = struct_value () [concrete] // CHECK:STDOUT: %IntResult.cpp_destructor.type: type = fn_type @IntResult.cpp_destructor [concrete] // CHECK:STDOUT: %IntResult.cpp_destructor: %IntResult.cpp_destructor.type = struct_value () [concrete] // CHECK:STDOUT: %LongResult.cpp_destructor.type: type = fn_type @LongResult.cpp_destructor [concrete] // CHECK:STDOUT: %LongResult.cpp_destructor: %LongResult.cpp_destructor.type = struct_value () [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { // CHECK:STDOUT: %Core: = namespace file.%Core.import, [concrete] { // CHECK:STDOUT: .CppCompat = %CppCompat.532 // CHECK:STDOUT: .ImplicitAs = %Core.ImplicitAs // CHECK:STDOUT: .Int = %Core.Int // CHECK:STDOUT: .Float = %Core.Float // CHECK:STDOUT: .As = %Core.As // CHECK:STDOUT: .Destroy = %Core.Destroy // CHECK:STDOUT: import Core//prelude // CHECK:STDOUT: import Core//prelude/... // CHECK:STDOUT: } // CHECK:STDOUT: %Cpp: = namespace file.%Cpp.import_cpp, [concrete] { // CHECK:STDOUT: .long = constants.%Cpp.long // CHECK:STDOUT: .LongResult = %LongResult.decl // CHECK:STDOUT: .PassLong = %PassLong.cpp_overload_set.value // CHECK:STDOUT: .IntResult = %IntResult.decl // CHECK:STDOUT: import Cpp//... // CHECK:STDOUT: } // CHECK:STDOUT: %Core.CppCompat: = import_ref Core//prelude, CppCompat, loaded // CHECK:STDOUT: %CppCompat.532: = namespace %Core.CppCompat, [concrete] { // CHECK:STDOUT: .Long32 = %Core.Long32 // CHECK:STDOUT: import Core//prelude // CHECK:STDOUT: import Core//prelude/... // CHECK:STDOUT: } // CHECK:STDOUT: %Core.Long32: type = import_ref Core//prelude/types/cpp/int, Long32, loaded [concrete = constants.%Cpp.long] // CHECK:STDOUT: %Core.ImplicitAs: %ImplicitAs.type.cc7 = import_ref Core//prelude/operators/as, ImplicitAs, loaded [concrete = constants.%ImplicitAs.generic] // CHECK:STDOUT: %Core.import_ref.0ba: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.2be = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.a1f] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.dc9 = impl_witness_table (%Core.import_ref.0ba), @Core.IntLiteral.as.ImplicitAs.impl.7e2 [concrete] // CHECK:STDOUT: %LongResult.decl: type = class_decl @LongResult [concrete = constants.%LongResult] {} {} // CHECK:STDOUT: %PassLong.cpp_overload_set.value: %PassLong.cpp_overload_set.type = cpp_overload_set_value @PassLong.cpp_overload_set [concrete = constants.%PassLong.cpp_overload_set.value] // CHECK:STDOUT: %PassLong__carbon_thunk.decl.d16229.1: %PassLong__carbon_thunk.type.9d9430.1 = fn_decl @PassLong__carbon_thunk.1 [concrete = constants.%PassLong__carbon_thunk.58a8f3.1] { // CHECK:STDOUT: // CHECK:STDOUT: } { // CHECK:STDOUT: // CHECK:STDOUT: } // CHECK:STDOUT: %Core.Int: %Int.type = import_ref Core//prelude/types/int, Int, loaded [concrete = constants.%Int.generic] // CHECK:STDOUT: %Core.import_ref.1a1: %Cpp.long.as.ImplicitAs.impl.Convert.type.395 = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long.as.ImplicitAs.impl.Convert.e43] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.90c = impl_witness_table (%Core.import_ref.1a1), @Cpp.long.as.ImplicitAs.impl.bf8 [concrete] // CHECK:STDOUT: %IntResult.decl: type = class_decl @IntResult [concrete = constants.%IntResult] {} {} // CHECK:STDOUT: %PassLong__carbon_thunk.decl.d16229.2: %PassLong__carbon_thunk.type.9d9430.2 = fn_decl @PassLong__carbon_thunk.2 [concrete = constants.%PassLong__carbon_thunk.58a8f3.2] { // CHECK:STDOUT: // CHECK:STDOUT: } { // CHECK:STDOUT: // CHECK:STDOUT: } // CHECK:STDOUT: %Core.Float: %Float.type = import_ref Core//prelude/types/float, Float, loaded [concrete = constants.%Float.generic] // CHECK:STDOUT: %Core.As: %As.type.90f = import_ref Core//prelude/operators/as, As, loaded [concrete = constants.%As.generic] // CHECK:STDOUT: %Core.import_ref.933: %Core.IntLiteral.as.As.impl.Convert.type = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Core.IntLiteral.as.As.impl.Convert] // CHECK:STDOUT: %As.impl_witness_table = impl_witness_table (%Core.import_ref.933), @Core.IntLiteral.as.As.impl.56c [concrete] // CHECK:STDOUT: %Core.import_ref.7b3: %Cpp.long.as.ImplicitAs.impl.Convert.type.eba = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.long.as.ImplicitAs.impl.Convert.082] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.d3d = impl_witness_table (%Core.import_ref.7b3), @Cpp.long.as.ImplicitAs.impl.29b [concrete] // CHECK:STDOUT: %Core.import_ref.cf3: @Core.FloatLiteral.as.ImplicitAs.impl.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.type (%Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.fd4) = import_ref Core//prelude/types/float, loc{{\d+_\d+}}, loaded [symbolic = @Core.FloatLiteral.as.ImplicitAs.impl.%Core.FloatLiteral.as.ImplicitAs.impl.Convert (constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.094)] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.d6a = impl_witness_table (%Core.import_ref.cf3), @Core.FloatLiteral.as.ImplicitAs.impl [concrete] // CHECK:STDOUT: %Core.Destroy: type = import_ref Core//prelude/destroy, Destroy, loaded [concrete = constants.%Destroy.type] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: fn @F() { // CHECK:STDOUT: !entry: // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %cpp_long.patt: %pattern_type.68c = value_binding_pattern cpp_long [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %int_1.loc15: Core.IntLiteral = int_value 1 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %.loc15_20: type = splice_block %long.ref.loc15 [concrete = constants.%Cpp.long] { // CHECK:STDOUT: %Cpp.ref.loc15: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %long.ref.loc15: type = name_ref long, constants.%Cpp.long [concrete = constants.%Cpp.long] // CHECK:STDOUT: } // CHECK:STDOUT: %impl.elem0.loc15: %.e52 = impl_witness_access constants.%ImplicitAs.impl_witness.ab8, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.a1f] // CHECK:STDOUT: %bound_method.loc15: = bound_method %int_1.loc15, %impl.elem0.loc15 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call: init %Cpp.long = call %bound_method.loc15(%int_1.loc15) [concrete = constants.%int_1.5a4] // CHECK:STDOUT: %.loc15_28.1: %Cpp.long = value_of_initializer %Core.IntLiteral.as.ImplicitAs.impl.Convert.call [concrete = constants.%int_1.5a4] // CHECK:STDOUT: %.loc15_28.2: %Cpp.long = converted %int_1.loc15, %.loc15_28.1 [concrete = constants.%int_1.5a4] // CHECK:STDOUT: %cpp_long: %Cpp.long = value_binding cpp_long, %.loc15_28.2 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %cpp_long_result.patt: %pattern_type.cd9 = value_binding_pattern cpp_long_result [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %Cpp.ref.loc16_41: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %PassLong.ref.loc16: %PassLong.cpp_overload_set.type = name_ref PassLong, imports.%PassLong.cpp_overload_set.value [concrete = constants.%PassLong.cpp_overload_set.value] // CHECK:STDOUT: %cpp_long.ref.loc16: %Cpp.long = name_ref cpp_long, %cpp_long // CHECK:STDOUT: %.loc16_62.1: ref %LongResult = temporary_storage // CHECK:STDOUT: %addr.loc16: %ptr.305 = addr_of %.loc16_62.1 // CHECK:STDOUT: %PassLong__carbon_thunk.call.loc16: init %empty_tuple.type = call imports.%PassLong__carbon_thunk.decl.d16229.1(%cpp_long.ref.loc16, %addr.loc16) // CHECK:STDOUT: %.loc16_62.2: init %LongResult = in_place_init %PassLong__carbon_thunk.call.loc16, %.loc16_62.1 // CHECK:STDOUT: %.loc16_27: type = splice_block %LongResult.ref.loc16 [concrete = constants.%LongResult] { // CHECK:STDOUT: %Cpp.ref.loc16_24: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %LongResult.ref.loc16: type = name_ref LongResult, imports.%LongResult.decl [concrete = constants.%LongResult] // CHECK:STDOUT: } // CHECK:STDOUT: %.loc16_62.3: ref %LongResult = temporary %.loc16_62.1, %.loc16_62.2 // CHECK:STDOUT: %.loc16_62.4: %LongResult = acquire_value %.loc16_62.3 // CHECK:STDOUT: %cpp_long_result: %LongResult = value_binding cpp_long_result, %.loc16_62.4 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %cpp_compat_long.patt: %pattern_type.68c = value_binding_pattern cpp_compat_long [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %cpp_long.ref.loc18: %Cpp.long = name_ref cpp_long, %cpp_long // CHECK:STDOUT: %.loc18: type = splice_block %Long32.ref [concrete = constants.%Cpp.long] { // CHECK:STDOUT: %Core.ref: = name_ref Core, imports.%Core [concrete = imports.%Core] // CHECK:STDOUT: %CppCompat.ref: = name_ref CppCompat, imports.%CppCompat.532 [concrete = imports.%CppCompat.532] // CHECK:STDOUT: %Long32.ref: type = name_ref Long32, imports.%Core.Long32 [concrete = constants.%Cpp.long] // CHECK:STDOUT: } // CHECK:STDOUT: %cpp_compat_long: %Cpp.long = value_binding cpp_compat_long, %cpp_long.ref.loc18 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %cpp_compat_long_result.patt: %pattern_type.cd9 = value_binding_pattern cpp_compat_long_result [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %Cpp.ref.loc19_48: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %PassLong.ref.loc19: %PassLong.cpp_overload_set.type = name_ref PassLong, imports.%PassLong.cpp_overload_set.value [concrete = constants.%PassLong.cpp_overload_set.value] // CHECK:STDOUT: %cpp_compat_long.ref: %Cpp.long = name_ref cpp_compat_long, %cpp_compat_long // CHECK:STDOUT: %.loc19_76.1: ref %LongResult = temporary_storage // CHECK:STDOUT: %addr.loc19: %ptr.305 = addr_of %.loc19_76.1 // CHECK:STDOUT: %PassLong__carbon_thunk.call.loc19: init %empty_tuple.type = call imports.%PassLong__carbon_thunk.decl.d16229.1(%cpp_compat_long.ref, %addr.loc19) // CHECK:STDOUT: %.loc19_76.2: init %LongResult = in_place_init %PassLong__carbon_thunk.call.loc19, %.loc19_76.1 // CHECK:STDOUT: %.loc19_34: type = splice_block %LongResult.ref.loc19 [concrete = constants.%LongResult] { // CHECK:STDOUT: %Cpp.ref.loc19_31: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %LongResult.ref.loc19: type = name_ref LongResult, imports.%LongResult.decl [concrete = constants.%LongResult] // CHECK:STDOUT: } // CHECK:STDOUT: %.loc19_76.3: ref %LongResult = temporary %.loc19_76.1, %.loc19_76.2 // CHECK:STDOUT: %.loc19_76.4: %LongResult = acquire_value %.loc19_76.3 // CHECK:STDOUT: %cpp_compat_long_result: %LongResult = value_binding cpp_compat_long_result, %.loc19_76.4 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %carbon_i32.patt: %pattern_type.7ce = value_binding_pattern carbon_i32 [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %cpp_long.ref.loc21: %Cpp.long = name_ref cpp_long, %cpp_long // CHECK:STDOUT: %.loc21_19: type = splice_block %i32 [concrete = constants.%i32] { // CHECK:STDOUT: %int_32.loc21: Core.IntLiteral = int_value 32 [concrete = constants.%int_32] // CHECK:STDOUT: %i32: type = class_type @Int, @Int(constants.%int_32) [concrete = constants.%i32] // CHECK:STDOUT: } // CHECK:STDOUT: %impl.elem0.loc21: %.261 = impl_witness_access constants.%ImplicitAs.impl_witness.c39, element0 [concrete = constants.%Cpp.long.as.ImplicitAs.impl.Convert.e43] // CHECK:STDOUT: %bound_method.loc21: = bound_method %cpp_long.ref.loc21, %impl.elem0.loc21 // CHECK:STDOUT: %Cpp.long.as.ImplicitAs.impl.Convert.call.loc21: init %i32 = call %bound_method.loc21(%cpp_long.ref.loc21) // CHECK:STDOUT: %.loc21_25.1: %i32 = value_of_initializer %Cpp.long.as.ImplicitAs.impl.Convert.call.loc21 // CHECK:STDOUT: %.loc21_25.2: %i32 = converted %cpp_long.ref.loc21, %.loc21_25.1 // CHECK:STDOUT: %carbon_i32: %i32 = value_binding carbon_i32, %.loc21_25.2 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %carbon_i32_result.patt: %pattern_type.454 = value_binding_pattern carbon_i32_result [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %Cpp.ref.loc22_42: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %PassLong.ref.loc22: %PassLong.cpp_overload_set.type = name_ref PassLong, imports.%PassLong.cpp_overload_set.value [concrete = constants.%PassLong.cpp_overload_set.value] // CHECK:STDOUT: %carbon_i32.ref: %i32 = name_ref carbon_i32, %carbon_i32 // CHECK:STDOUT: %.loc22_65.1: ref %IntResult = temporary_storage // CHECK:STDOUT: %addr.loc22: %ptr.3cb = addr_of %.loc22_65.1 // CHECK:STDOUT: %PassLong__carbon_thunk.call.loc22: init %empty_tuple.type = call imports.%PassLong__carbon_thunk.decl.d16229.2(%carbon_i32.ref, %addr.loc22) // CHECK:STDOUT: %.loc22_65.2: init %IntResult = in_place_init %PassLong__carbon_thunk.call.loc22, %.loc22_65.1 // CHECK:STDOUT: %.loc22_29: type = splice_block %IntResult.ref [concrete = constants.%IntResult] { // CHECK:STDOUT: %Cpp.ref.loc22_26: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %IntResult.ref: type = name_ref IntResult, imports.%IntResult.decl [concrete = constants.%IntResult] // CHECK:STDOUT: } // CHECK:STDOUT: %.loc22_65.3: ref %IntResult = temporary %.loc22_65.1, %.loc22_65.2 // CHECK:STDOUT: %.loc22_65.4: %IntResult = acquire_value %.loc22_65.3 // CHECK:STDOUT: %carbon_i32_result: %IntResult = value_binding carbon_i32_result, %.loc22_65.4 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %a.patt: %pattern_type.b36 = ref_binding_pattern a [concrete] // CHECK:STDOUT: %a.var_patt: %pattern_type.b36 = var_pattern %a.patt [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %a.var: ref %array_type = var %a.var_patt // CHECK:STDOUT: %float: Core.FloatLiteral = float_literal_value 10e-1 [concrete = constants.%float.674] // CHECK:STDOUT: %.loc24_43.1: %tuple.type = tuple_literal (%float) [concrete = constants.%tuple] // CHECK:STDOUT: %impl.elem0.loc24_43: %.b83 = impl_witness_access constants.%ImplicitAs.impl_witness.d25, element0 [concrete = constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8] // CHECK:STDOUT: %bound_method.loc24_43.1: = bound_method %float, %impl.elem0.loc24_43 [concrete = constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.bound] // CHECK:STDOUT: %specific_fn: = specific_function %impl.elem0.loc24_43, @Core.FloatLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.specific_fn] // CHECK:STDOUT: %bound_method.loc24_43.2: = bound_method %float, %specific_fn [concrete = constants.%bound_method] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.call: init %f32.97e = call %bound_method.loc24_43.2(%float) [concrete = constants.%float.e3b] // CHECK:STDOUT: %.loc24_43.2: init %f32.97e = converted %float, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.call [concrete = constants.%float.e3b] // CHECK:STDOUT: %int_0: Core.IntLiteral = int_value 0 [concrete = constants.%int_0] // CHECK:STDOUT: %.loc24_43.3: ref %f32.97e = array_index %a.var, %int_0 // CHECK:STDOUT: %.loc24_43.4: init %f32.97e = initialize_from %.loc24_43.2 to %.loc24_43.3 [concrete = constants.%float.e3b] // CHECK:STDOUT: %.loc24_43.5: init %array_type = array_init (%.loc24_43.4) to %a.var [concrete = constants.%array] // CHECK:STDOUT: %.loc24_3: init %array_type = converted %.loc24_43.1, %.loc24_43.5 [concrete = constants.%array] // CHECK:STDOUT: assign %a.var, %.loc24_3 // CHECK:STDOUT: %.loc24_34: type = splice_block %array_type [concrete = constants.%array_type] { // CHECK:STDOUT: %int_32.loc24: Core.IntLiteral = int_value 32 [concrete = constants.%int_32] // CHECK:STDOUT: %f32: type = class_type @Float, @Float(constants.%int_32) [concrete = constants.%f32.97e] // CHECK:STDOUT: %int_1.loc24: Core.IntLiteral = int_value 1 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %Cpp.ref.loc24: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %long.ref.loc24: type = name_ref long, constants.%Cpp.long [concrete = constants.%Cpp.long] // CHECK:STDOUT: %impl.elem0.loc24_23.1: %.751 = impl_witness_access constants.%As.impl_witness, element0 [concrete = constants.%Core.IntLiteral.as.As.impl.Convert] // CHECK:STDOUT: %bound_method.loc24_23.1: = bound_method %int_1.loc24, %impl.elem0.loc24_23.1 [concrete = constants.%Core.IntLiteral.as.As.impl.Convert.bound] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.call: init %Cpp.long = call %bound_method.loc24_23.1(%int_1.loc24) [concrete = constants.%int_1.5a4] // CHECK:STDOUT: %.loc24_23.1: %Cpp.long = value_of_initializer %Core.IntLiteral.as.As.impl.Convert.call [concrete = constants.%int_1.5a4] // CHECK:STDOUT: %.loc24_23.2: %Cpp.long = converted %int_1.loc24, %.loc24_23.1 [concrete = constants.%int_1.5a4] // CHECK:STDOUT: %impl.elem0.loc24_23.2: %.907 = impl_witness_access constants.%ImplicitAs.impl_witness.1e0, element0 [concrete = constants.%Cpp.long.as.ImplicitAs.impl.Convert.082] // CHECK:STDOUT: %bound_method.loc24_23.2: = bound_method %.loc24_23.2, %impl.elem0.loc24_23.2 [concrete = constants.%Cpp.long.as.ImplicitAs.impl.Convert.bound] // CHECK:STDOUT: %Cpp.long.as.ImplicitAs.impl.Convert.call.loc24: init Core.IntLiteral = call %bound_method.loc24_23.2(%.loc24_23.2) [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %.loc24_23.3: Core.IntLiteral = value_of_initializer %Cpp.long.as.ImplicitAs.impl.Convert.call.loc24 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %.loc24_23.4: Core.IntLiteral = converted %.loc24_23.2, %.loc24_23.3 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %array_type: type = array_type %.loc24_23.4, %f32 [concrete = constants.%array_type] // CHECK:STDOUT: } // CHECK:STDOUT: %a: ref %array_type = ref_binding a, %a.var // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.bound: = bound_method %a.var, constants.%DestroyT.binding.as_type.as.Destroy.impl.Op.9ec // CHECK:STDOUT: // CHECK:STDOUT: %bound_method.loc24_3: = bound_method %a.var, %DestroyT.binding.as_type.as.Destroy.impl.Op.specific_fn // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.call: init %empty_tuple.type = call %bound_method.loc24_3(%a.var) // CHECK:STDOUT: %IntResult.cpp_destructor.bound: = bound_method %.loc22_65.3, constants.%IntResult.cpp_destructor // CHECK:STDOUT: %IntResult.cpp_destructor.call: init %empty_tuple.type = call %IntResult.cpp_destructor.bound(%.loc22_65.3) // CHECK:STDOUT: %LongResult.cpp_destructor.bound.loc19: = bound_method %.loc19_76.3, constants.%LongResult.cpp_destructor // CHECK:STDOUT: %LongResult.cpp_destructor.call.loc19: init %empty_tuple.type = call %LongResult.cpp_destructor.bound.loc19(%.loc19_76.3) // CHECK:STDOUT: %LongResult.cpp_destructor.bound.loc16: = bound_method %.loc16_62.3, constants.%LongResult.cpp_destructor // CHECK:STDOUT: %LongResult.cpp_destructor.call.loc16: init %empty_tuple.type = call %LongResult.cpp_destructor.bound.loc16(%.loc16_62.3) // CHECK:STDOUT: // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: --- unsigned_long.carbon // CHECK:STDOUT: // CHECK:STDOUT: constants { // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete] // CHECK:STDOUT: %Cpp.unsigned_long: type = class_type @ULong32 [concrete] // CHECK:STDOUT: %int_32: Core.IntLiteral = int_value 32 [concrete] // CHECK:STDOUT: %UInt.type: type = generic_class_type @UInt [concrete] // CHECK:STDOUT: %UInt.generic: %UInt.type = struct_value () [concrete] // CHECK:STDOUT: %N: Core.IntLiteral = symbolic_binding N, 0 [symbolic] // CHECK:STDOUT: %u32: type = class_type @UInt, @UInt(%int_32) [concrete] // CHECK:STDOUT: %pattern_type.5b7: type = pattern_type %Cpp.unsigned_long [concrete] // CHECK:STDOUT: %int_1.5b8: Core.IntLiteral = int_value 1 [concrete] // CHECK:STDOUT: %ImplicitAs.type.cc7: type = generic_interface_type @ImplicitAs [concrete] // CHECK:STDOUT: %ImplicitAs.generic: %ImplicitAs.type.cc7 = struct_value () [concrete] // CHECK:STDOUT: %ImplicitAs.type.b0a: type = facet_type <@ImplicitAs, @ImplicitAs(%Cpp.unsigned_long)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.691: type = fn_type @ImplicitAs.Convert, @ImplicitAs(%Cpp.unsigned_long) [concrete] // CHECK:STDOUT: %ImplicitAs.type.7a9: type = facet_type <@ImplicitAs, @ImplicitAs(Core.IntLiteral)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.71e: type = fn_type @ImplicitAs.Convert, @ImplicitAs(Core.IntLiteral) [concrete] // CHECK:STDOUT: %ImplicitAs.type.9e2: type = facet_type <@ImplicitAs, @ImplicitAs(%u32)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.92a: type = fn_type @ImplicitAs.Convert, @ImplicitAs(%u32) [concrete] // CHECK:STDOUT: %ImplicitAs.impl_witness.ade: = impl_witness imports.%ImplicitAs.impl_witness_table.863 [concrete] // CHECK:STDOUT: %ImplicitAs.facet.cdd: %ImplicitAs.type.b0a = facet_value Core.IntLiteral, (%ImplicitAs.impl_witness.ade) [concrete] // CHECK:STDOUT: %.3e6: type = fn_type_with_self_type %ImplicitAs.Convert.type.691, %ImplicitAs.facet.cdd [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.12f: type = fn_type @Core.IntLiteral.as.ImplicitAs.impl.Convert.1 [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.076: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.12f = struct_value () [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.bound: = bound_method %int_1.5b8, %Core.IntLiteral.as.ImplicitAs.impl.Convert.076 [concrete] // CHECK:STDOUT: %int_1.0ab: %Cpp.unsigned_long = int_value 1 [concrete] // CHECK:STDOUT: %ULongResult: type = class_type @ULongResult [concrete] // CHECK:STDOUT: %pattern_type.6f2: type = pattern_type %ULongResult [concrete] // CHECK:STDOUT: %PassULong.cpp_overload_set.type: type = cpp_overload_set_type @PassULong.cpp_overload_set [concrete] // CHECK:STDOUT: %PassULong.cpp_overload_set.value: %PassULong.cpp_overload_set.type = cpp_overload_set_value @PassULong.cpp_overload_set [concrete] // CHECK:STDOUT: %ptr.f5e: type = ptr_type %ULongResult [concrete] // CHECK:STDOUT: %PassULong__carbon_thunk.type.3fc2d8.1: type = fn_type @PassULong__carbon_thunk.1 [concrete] // CHECK:STDOUT: %PassULong__carbon_thunk.ff747d.1: %PassULong__carbon_thunk.type.3fc2d8.1 = struct_value () [concrete] // CHECK:STDOUT: %pattern_type.4a9: type = pattern_type %u32 [concrete] // CHECK:STDOUT: %ImplicitAs.impl_witness.c73: = impl_witness imports.%ImplicitAs.impl_witness_table.5ff [concrete] // CHECK:STDOUT: %ImplicitAs.facet.1b5: %ImplicitAs.type.9e2 = facet_value %Cpp.unsigned_long, (%ImplicitAs.impl_witness.c73) [concrete] // CHECK:STDOUT: %.a17: type = fn_type_with_self_type %ImplicitAs.Convert.type.92a, %ImplicitAs.facet.1b5 [concrete] // CHECK:STDOUT: %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.type.c43: type = fn_type @Cpp.unsigned_long.as.ImplicitAs.impl.Convert.1 [concrete] // CHECK:STDOUT: %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.76d: %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.type.c43 = struct_value () [concrete] // CHECK:STDOUT: %UIntResult: type = class_type @UIntResult [concrete] // CHECK:STDOUT: %pattern_type.dc7: type = pattern_type %UIntResult [concrete] // CHECK:STDOUT: %ptr.059: type = ptr_type %UIntResult [concrete] // CHECK:STDOUT: %PassULong__carbon_thunk.type.3fc2d8.2: type = fn_type @PassULong__carbon_thunk.2 [concrete] // CHECK:STDOUT: %PassULong__carbon_thunk.ff747d.2: %PassULong__carbon_thunk.type.3fc2d8.2 = struct_value () [concrete] // CHECK:STDOUT: %Float.type: type = generic_class_type @Float [concrete] // CHECK:STDOUT: %Float.generic: %Float.type = struct_value () [concrete] // CHECK:STDOUT: %f32.97e: type = class_type @Float, @Float(%int_32) [concrete] // CHECK:STDOUT: %As.type.90f: type = generic_interface_type @As [concrete] // CHECK:STDOUT: %As.generic: %As.type.90f = struct_value () [concrete] // CHECK:STDOUT: %As.type.042: type = facet_type <@As, @As(%Cpp.unsigned_long)> [concrete] // CHECK:STDOUT: %As.Convert.type.3ff: type = fn_type @As.Convert, @As(%Cpp.unsigned_long) [concrete] // CHECK:STDOUT: %As.impl_witness: = impl_witness imports.%As.impl_witness_table [concrete] // CHECK:STDOUT: %As.facet: %As.type.042 = facet_value Core.IntLiteral, (%As.impl_witness) [concrete] // CHECK:STDOUT: %.79d: type = fn_type_with_self_type %As.Convert.type.3ff, %As.facet [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.type: type = fn_type @Core.IntLiteral.as.As.impl.Convert [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert: %Core.IntLiteral.as.As.impl.Convert.type = struct_value () [concrete] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.bound: = bound_method %int_1.5b8, %Core.IntLiteral.as.As.impl.Convert [concrete] // CHECK:STDOUT: %ImplicitAs.impl_witness.83c: = impl_witness imports.%ImplicitAs.impl_witness_table.306 [concrete] // CHECK:STDOUT: %ImplicitAs.facet.a43: %ImplicitAs.type.7a9 = facet_value %Cpp.unsigned_long, (%ImplicitAs.impl_witness.83c) [concrete] // CHECK:STDOUT: %.31b: type = fn_type_with_self_type %ImplicitAs.Convert.type.71e, %ImplicitAs.facet.a43 [concrete] // CHECK:STDOUT: %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.type.853: type = fn_type @Cpp.unsigned_long.as.ImplicitAs.impl.Convert.2 [concrete] // CHECK:STDOUT: %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.531: %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.type.853 = struct_value () [concrete] // CHECK:STDOUT: %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.bound: = bound_method %int_1.0ab, %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.531 [concrete] // CHECK:STDOUT: %array_type: type = array_type %int_1.5b8, %f32.97e [concrete] // CHECK:STDOUT: %pattern_type.b36: type = pattern_type %array_type [concrete] // CHECK:STDOUT: %float.674: Core.FloatLiteral = float_literal_value 10e-1 [concrete] // CHECK:STDOUT: %tuple.type: type = tuple_type (Core.FloatLiteral) [concrete] // CHECK:STDOUT: %tuple: %tuple.type = tuple_value (%float.674) [concrete] // CHECK:STDOUT: %int_0: Core.IntLiteral = int_value 0 [concrete] // CHECK:STDOUT: %ImplicitAs.type.921: type = facet_type <@ImplicitAs, @ImplicitAs(%f32.97e)> [concrete] // CHECK:STDOUT: %ImplicitAs.Convert.type.b8c: type = fn_type @ImplicitAs.Convert, @ImplicitAs(%f32.97e) [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.fd4: type = fn_type @Core.FloatLiteral.as.ImplicitAs.impl.Convert, @Core.FloatLiteral.as.ImplicitAs.impl(%N) [symbolic] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.094: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.fd4 = struct_value () [symbolic] // CHECK:STDOUT: %ImplicitAs.impl_witness.d25: = impl_witness imports.%ImplicitAs.impl_witness_table.d6a, @Core.FloatLiteral.as.ImplicitAs.impl(%int_32) [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.85a: type = fn_type @Core.FloatLiteral.as.ImplicitAs.impl.Convert, @Core.FloatLiteral.as.ImplicitAs.impl(%int_32) [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.85a = struct_value () [concrete] // CHECK:STDOUT: %ImplicitAs.facet.9b7: %ImplicitAs.type.921 = facet_value Core.FloatLiteral, (%ImplicitAs.impl_witness.d25) [concrete] // CHECK:STDOUT: %.b83: type = fn_type_with_self_type %ImplicitAs.Convert.type.b8c, %ImplicitAs.facet.9b7 [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.bound: = bound_method %float.674, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8 [concrete] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.specific_fn: = specific_function %Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8, @Core.FloatLiteral.as.ImplicitAs.impl.Convert(%int_32) [concrete] // CHECK:STDOUT: %bound_method: = bound_method %float.674, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete] // CHECK:STDOUT: %float.e3b: %f32.97e = float_value 1 [concrete] // CHECK:STDOUT: %array: %array_type = tuple_value (%float.e3b) [concrete] // CHECK:STDOUT: %Destroy.type: type = facet_type <@Destroy> [concrete] // CHECK:STDOUT: %type_where: type = facet_type > [concrete] // CHECK:STDOUT: %facet_value.cee: %type_where = facet_value %array_type, () [concrete] // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.type.fb2: type = fn_type @DestroyT.binding.as_type.as.Destroy.impl.Op, @DestroyT.binding.as_type.as.Destroy.impl(%facet_value.cee) [concrete] // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.9ec: %DestroyT.binding.as_type.as.Destroy.impl.Op.type.fb2 = struct_value () [concrete] // CHECK:STDOUT: %UIntResult.cpp_destructor.type: type = fn_type @UIntResult.cpp_destructor [concrete] // CHECK:STDOUT: %UIntResult.cpp_destructor: %UIntResult.cpp_destructor.type = struct_value () [concrete] // CHECK:STDOUT: %ULongResult.cpp_destructor.type: type = fn_type @ULongResult.cpp_destructor [concrete] // CHECK:STDOUT: %ULongResult.cpp_destructor: %ULongResult.cpp_destructor.type = struct_value () [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: imports { // CHECK:STDOUT: %Core: = namespace file.%Core.import, [concrete] { // CHECK:STDOUT: .CppCompat = %CppCompat.532 // CHECK:STDOUT: .ImplicitAs = %Core.ImplicitAs // CHECK:STDOUT: .UInt = %Core.UInt // CHECK:STDOUT: .Float = %Core.Float // CHECK:STDOUT: .As = %Core.As // CHECK:STDOUT: .Destroy = %Core.Destroy // CHECK:STDOUT: import Core//prelude // CHECK:STDOUT: import Core//prelude/... // CHECK:STDOUT: } // CHECK:STDOUT: %Cpp: = namespace file.%Cpp.import_cpp, [concrete] { // CHECK:STDOUT: .unsigned_long = constants.%Cpp.unsigned_long // CHECK:STDOUT: .ULongResult = %ULongResult.decl // CHECK:STDOUT: .PassULong = %PassULong.cpp_overload_set.value // CHECK:STDOUT: .UIntResult = %UIntResult.decl // CHECK:STDOUT: import Cpp//... // CHECK:STDOUT: } // CHECK:STDOUT: %Core.CppCompat: = import_ref Core//prelude, CppCompat, loaded // CHECK:STDOUT: %CppCompat.532: = namespace %Core.CppCompat, [concrete] { // CHECK:STDOUT: .ULong32 = %Core.ULong32 // CHECK:STDOUT: import Core//prelude // CHECK:STDOUT: import Core//prelude/... // CHECK:STDOUT: } // CHECK:STDOUT: %Core.ULong32: type = import_ref Core//prelude/types/cpp/int, ULong32, loaded [concrete = constants.%Cpp.unsigned_long] // CHECK:STDOUT: %Core.ImplicitAs: %ImplicitAs.type.cc7 = import_ref Core//prelude/operators/as, ImplicitAs, loaded [concrete = constants.%ImplicitAs.generic] // CHECK:STDOUT: %Core.import_ref.849: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.12f = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.076] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.863 = impl_witness_table (%Core.import_ref.849), @Core.IntLiteral.as.ImplicitAs.impl.eac [concrete] // CHECK:STDOUT: %ULongResult.decl: type = class_decl @ULongResult [concrete = constants.%ULongResult] {} {} // CHECK:STDOUT: %PassULong.cpp_overload_set.value: %PassULong.cpp_overload_set.type = cpp_overload_set_value @PassULong.cpp_overload_set [concrete = constants.%PassULong.cpp_overload_set.value] // CHECK:STDOUT: %PassULong__carbon_thunk.decl.108234.1: %PassULong__carbon_thunk.type.3fc2d8.1 = fn_decl @PassULong__carbon_thunk.1 [concrete = constants.%PassULong__carbon_thunk.ff747d.1] { // CHECK:STDOUT: // CHECK:STDOUT: } { // CHECK:STDOUT: // CHECK:STDOUT: } // CHECK:STDOUT: %Core.UInt: %UInt.type = import_ref Core//prelude/types/uint, UInt, loaded [concrete = constants.%UInt.generic] // CHECK:STDOUT: %Core.import_ref.fa0: %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.type.c43 = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.unsigned_long.as.ImplicitAs.impl.Convert.76d] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.5ff = impl_witness_table (%Core.import_ref.fa0), @Cpp.unsigned_long.as.ImplicitAs.impl.603 [concrete] // CHECK:STDOUT: %UIntResult.decl: type = class_decl @UIntResult [concrete = constants.%UIntResult] {} {} // CHECK:STDOUT: %PassULong__carbon_thunk.decl.108234.2: %PassULong__carbon_thunk.type.3fc2d8.2 = fn_decl @PassULong__carbon_thunk.2 [concrete = constants.%PassULong__carbon_thunk.ff747d.2] { // CHECK:STDOUT: // CHECK:STDOUT: } { // CHECK:STDOUT: // CHECK:STDOUT: } // CHECK:STDOUT: %Core.Float: %Float.type = import_ref Core//prelude/types/float, Float, loaded [concrete = constants.%Float.generic] // CHECK:STDOUT: %Core.As: %As.type.90f = import_ref Core//prelude/operators/as, As, loaded [concrete = constants.%As.generic] // CHECK:STDOUT: %Core.import_ref.9c4: %Core.IntLiteral.as.As.impl.Convert.type = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Core.IntLiteral.as.As.impl.Convert] // CHECK:STDOUT: %As.impl_witness_table = impl_witness_table (%Core.import_ref.9c4), @Core.IntLiteral.as.As.impl.ae4 [concrete] // CHECK:STDOUT: %Core.import_ref.1665: %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.type.853 = import_ref Core//prelude/types/cpp/int, loc{{\d+_\d+}}, loaded [concrete = constants.%Cpp.unsigned_long.as.ImplicitAs.impl.Convert.531] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.306 = impl_witness_table (%Core.import_ref.1665), @Cpp.unsigned_long.as.ImplicitAs.impl.bf1 [concrete] // CHECK:STDOUT: %Core.import_ref.cf3: @Core.FloatLiteral.as.ImplicitAs.impl.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.type (%Core.FloatLiteral.as.ImplicitAs.impl.Convert.type.fd4) = import_ref Core//prelude/types/float, loc{{\d+_\d+}}, loaded [symbolic = @Core.FloatLiteral.as.ImplicitAs.impl.%Core.FloatLiteral.as.ImplicitAs.impl.Convert (constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.094)] // CHECK:STDOUT: %ImplicitAs.impl_witness_table.d6a = impl_witness_table (%Core.import_ref.cf3), @Core.FloatLiteral.as.ImplicitAs.impl [concrete] // CHECK:STDOUT: %Core.Destroy: type = import_ref Core//prelude/destroy, Destroy, loaded [concrete = constants.%Destroy.type] // CHECK:STDOUT: } // CHECK:STDOUT: // CHECK:STDOUT: fn @F() { // CHECK:STDOUT: !entry: // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %cpp_unsigned_long.patt: %pattern_type.5b7 = value_binding_pattern cpp_unsigned_long [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %int_1.loc15: Core.IntLiteral = int_value 1 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %.loc15_29: type = splice_block %unsigned_long.ref.loc15 [concrete = constants.%Cpp.unsigned_long] { // CHECK:STDOUT: %Cpp.ref.loc15: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %unsigned_long.ref.loc15: type = name_ref unsigned_long, constants.%Cpp.unsigned_long [concrete = constants.%Cpp.unsigned_long] // CHECK:STDOUT: } // CHECK:STDOUT: %impl.elem0.loc15: %.3e6 = impl_witness_access constants.%ImplicitAs.impl_witness.ade, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.076] // CHECK:STDOUT: %bound_method.loc15: = bound_method %int_1.loc15, %impl.elem0.loc15 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound] // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call: init %Cpp.unsigned_long = call %bound_method.loc15(%int_1.loc15) [concrete = constants.%int_1.0ab] // CHECK:STDOUT: %.loc15_46.1: %Cpp.unsigned_long = value_of_initializer %Core.IntLiteral.as.ImplicitAs.impl.Convert.call [concrete = constants.%int_1.0ab] // CHECK:STDOUT: %.loc15_46.2: %Cpp.unsigned_long = converted %int_1.loc15, %.loc15_46.1 [concrete = constants.%int_1.0ab] // CHECK:STDOUT: %cpp_unsigned_long: %Cpp.unsigned_long = value_binding cpp_unsigned_long, %.loc15_46.2 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %cpp_unsigned_long_result.patt: %pattern_type.6f2 = value_binding_pattern cpp_unsigned_long_result [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %Cpp.ref.loc16_51: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %PassULong.ref.loc16: %PassULong.cpp_overload_set.type = name_ref PassULong, imports.%PassULong.cpp_overload_set.value [concrete = constants.%PassULong.cpp_overload_set.value] // CHECK:STDOUT: %cpp_unsigned_long.ref.loc16: %Cpp.unsigned_long = name_ref cpp_unsigned_long, %cpp_unsigned_long // CHECK:STDOUT: %.loc16_82.1: ref %ULongResult = temporary_storage // CHECK:STDOUT: %addr.loc16: %ptr.f5e = addr_of %.loc16_82.1 // CHECK:STDOUT: %PassULong__carbon_thunk.call.loc16: init %empty_tuple.type = call imports.%PassULong__carbon_thunk.decl.108234.1(%cpp_unsigned_long.ref.loc16, %addr.loc16) // CHECK:STDOUT: %.loc16_82.2: init %ULongResult = in_place_init %PassULong__carbon_thunk.call.loc16, %.loc16_82.1 // CHECK:STDOUT: %.loc16_36: type = splice_block %ULongResult.ref.loc16 [concrete = constants.%ULongResult] { // CHECK:STDOUT: %Cpp.ref.loc16_33: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %ULongResult.ref.loc16: type = name_ref ULongResult, imports.%ULongResult.decl [concrete = constants.%ULongResult] // CHECK:STDOUT: } // CHECK:STDOUT: %.loc16_82.3: ref %ULongResult = temporary %.loc16_82.1, %.loc16_82.2 // CHECK:STDOUT: %.loc16_82.4: %ULongResult = acquire_value %.loc16_82.3 // CHECK:STDOUT: %cpp_unsigned_long_result: %ULongResult = value_binding cpp_unsigned_long_result, %.loc16_82.4 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %cpp_compat_ulong.patt: %pattern_type.5b7 = value_binding_pattern cpp_compat_ulong [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %cpp_unsigned_long.ref.loc18: %Cpp.unsigned_long = name_ref cpp_unsigned_long, %cpp_unsigned_long // CHECK:STDOUT: %.loc18: type = splice_block %ULong32.ref [concrete = constants.%Cpp.unsigned_long] { // CHECK:STDOUT: %Core.ref: = name_ref Core, imports.%Core [concrete = imports.%Core] // CHECK:STDOUT: %CppCompat.ref: = name_ref CppCompat, imports.%CppCompat.532 [concrete = imports.%CppCompat.532] // CHECK:STDOUT: %ULong32.ref: type = name_ref ULong32, imports.%Core.ULong32 [concrete = constants.%Cpp.unsigned_long] // CHECK:STDOUT: } // CHECK:STDOUT: %cpp_compat_ulong: %Cpp.unsigned_long = value_binding cpp_compat_ulong, %cpp_unsigned_long.ref.loc18 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %cpp_compat_ulong_result.patt: %pattern_type.6f2 = value_binding_pattern cpp_compat_ulong_result [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %Cpp.ref.loc19_50: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %PassULong.ref.loc19: %PassULong.cpp_overload_set.type = name_ref PassULong, imports.%PassULong.cpp_overload_set.value [concrete = constants.%PassULong.cpp_overload_set.value] // CHECK:STDOUT: %cpp_compat_ulong.ref: %Cpp.unsigned_long = name_ref cpp_compat_ulong, %cpp_compat_ulong // CHECK:STDOUT: %.loc19_80.1: ref %ULongResult = temporary_storage // CHECK:STDOUT: %addr.loc19: %ptr.f5e = addr_of %.loc19_80.1 // CHECK:STDOUT: %PassULong__carbon_thunk.call.loc19: init %empty_tuple.type = call imports.%PassULong__carbon_thunk.decl.108234.1(%cpp_compat_ulong.ref, %addr.loc19) // CHECK:STDOUT: %.loc19_80.2: init %ULongResult = in_place_init %PassULong__carbon_thunk.call.loc19, %.loc19_80.1 // CHECK:STDOUT: %.loc19_35: type = splice_block %ULongResult.ref.loc19 [concrete = constants.%ULongResult] { // CHECK:STDOUT: %Cpp.ref.loc19_32: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %ULongResult.ref.loc19: type = name_ref ULongResult, imports.%ULongResult.decl [concrete = constants.%ULongResult] // CHECK:STDOUT: } // CHECK:STDOUT: %.loc19_80.3: ref %ULongResult = temporary %.loc19_80.1, %.loc19_80.2 // CHECK:STDOUT: %.loc19_80.4: %ULongResult = acquire_value %.loc19_80.3 // CHECK:STDOUT: %cpp_compat_ulong_result: %ULongResult = value_binding cpp_compat_ulong_result, %.loc19_80.4 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %carbon_u32.patt: %pattern_type.4a9 = value_binding_pattern carbon_u32 [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %cpp_unsigned_long.ref.loc21: %Cpp.unsigned_long = name_ref cpp_unsigned_long, %cpp_unsigned_long // CHECK:STDOUT: %.loc21_19: type = splice_block %u32 [concrete = constants.%u32] { // CHECK:STDOUT: %int_32.loc21: Core.IntLiteral = int_value 32 [concrete = constants.%int_32] // CHECK:STDOUT: %u32: type = class_type @UInt, @UInt(constants.%int_32) [concrete = constants.%u32] // CHECK:STDOUT: } // CHECK:STDOUT: %impl.elem0.loc21: %.a17 = impl_witness_access constants.%ImplicitAs.impl_witness.c73, element0 [concrete = constants.%Cpp.unsigned_long.as.ImplicitAs.impl.Convert.76d] // CHECK:STDOUT: %bound_method.loc21: = bound_method %cpp_unsigned_long.ref.loc21, %impl.elem0.loc21 // CHECK:STDOUT: %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.call.loc21: init %u32 = call %bound_method.loc21(%cpp_unsigned_long.ref.loc21) // CHECK:STDOUT: %.loc21_25.1: %u32 = value_of_initializer %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.call.loc21 // CHECK:STDOUT: %.loc21_25.2: %u32 = converted %cpp_unsigned_long.ref.loc21, %.loc21_25.1 // CHECK:STDOUT: %carbon_u32: %u32 = value_binding carbon_u32, %.loc21_25.2 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %carbon_u32_result.patt: %pattern_type.dc7 = value_binding_pattern carbon_u32_result [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %Cpp.ref.loc22_43: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %PassULong.ref.loc22: %PassULong.cpp_overload_set.type = name_ref PassULong, imports.%PassULong.cpp_overload_set.value [concrete = constants.%PassULong.cpp_overload_set.value] // CHECK:STDOUT: %carbon_u32.ref: %u32 = name_ref carbon_u32, %carbon_u32 // CHECK:STDOUT: %.loc22_67.1: ref %UIntResult = temporary_storage // CHECK:STDOUT: %addr.loc22: %ptr.059 = addr_of %.loc22_67.1 // CHECK:STDOUT: %PassULong__carbon_thunk.call.loc22: init %empty_tuple.type = call imports.%PassULong__carbon_thunk.decl.108234.2(%carbon_u32.ref, %addr.loc22) // CHECK:STDOUT: %.loc22_67.2: init %UIntResult = in_place_init %PassULong__carbon_thunk.call.loc22, %.loc22_67.1 // CHECK:STDOUT: %.loc22_29: type = splice_block %UIntResult.ref [concrete = constants.%UIntResult] { // CHECK:STDOUT: %Cpp.ref.loc22_26: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %UIntResult.ref: type = name_ref UIntResult, imports.%UIntResult.decl [concrete = constants.%UIntResult] // CHECK:STDOUT: } // CHECK:STDOUT: %.loc22_67.3: ref %UIntResult = temporary %.loc22_67.1, %.loc22_67.2 // CHECK:STDOUT: %.loc22_67.4: %UIntResult = acquire_value %.loc22_67.3 // CHECK:STDOUT: %carbon_u32_result: %UIntResult = value_binding carbon_u32_result, %.loc22_67.4 // CHECK:STDOUT: name_binding_decl { // CHECK:STDOUT: %a.patt: %pattern_type.b36 = ref_binding_pattern a [concrete] // CHECK:STDOUT: %a.var_patt: %pattern_type.b36 = var_pattern %a.patt [concrete] // CHECK:STDOUT: } // CHECK:STDOUT: %a.var: ref %array_type = var %a.var_patt // CHECK:STDOUT: %float: Core.FloatLiteral = float_literal_value 10e-1 [concrete = constants.%float.674] // CHECK:STDOUT: %.loc24_52.1: %tuple.type = tuple_literal (%float) [concrete = constants.%tuple] // CHECK:STDOUT: %impl.elem0.loc24_52: %.b83 = impl_witness_access constants.%ImplicitAs.impl_witness.d25, element0 [concrete = constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.4f8] // CHECK:STDOUT: %bound_method.loc24_52.1: = bound_method %float, %impl.elem0.loc24_52 [concrete = constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.bound] // CHECK:STDOUT: %specific_fn: = specific_function %impl.elem0.loc24_52, @Core.FloatLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.FloatLiteral.as.ImplicitAs.impl.Convert.specific_fn] // CHECK:STDOUT: %bound_method.loc24_52.2: = bound_method %float, %specific_fn [concrete = constants.%bound_method] // CHECK:STDOUT: %Core.FloatLiteral.as.ImplicitAs.impl.Convert.call: init %f32.97e = call %bound_method.loc24_52.2(%float) [concrete = constants.%float.e3b] // CHECK:STDOUT: %.loc24_52.2: init %f32.97e = converted %float, %Core.FloatLiteral.as.ImplicitAs.impl.Convert.call [concrete = constants.%float.e3b] // CHECK:STDOUT: %int_0: Core.IntLiteral = int_value 0 [concrete = constants.%int_0] // CHECK:STDOUT: %.loc24_52.3: ref %f32.97e = array_index %a.var, %int_0 // CHECK:STDOUT: %.loc24_52.4: init %f32.97e = initialize_from %.loc24_52.2 to %.loc24_52.3 [concrete = constants.%float.e3b] // CHECK:STDOUT: %.loc24_52.5: init %array_type = array_init (%.loc24_52.4) to %a.var [concrete = constants.%array] // CHECK:STDOUT: %.loc24_3: init %array_type = converted %.loc24_52.1, %.loc24_52.5 [concrete = constants.%array] // CHECK:STDOUT: assign %a.var, %.loc24_3 // CHECK:STDOUT: %.loc24_43: type = splice_block %array_type [concrete = constants.%array_type] { // CHECK:STDOUT: %int_32.loc24: Core.IntLiteral = int_value 32 [concrete = constants.%int_32] // CHECK:STDOUT: %f32: type = class_type @Float, @Float(constants.%int_32) [concrete = constants.%f32.97e] // CHECK:STDOUT: %int_1.loc24: Core.IntLiteral = int_value 1 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %Cpp.ref.loc24: = name_ref Cpp, imports.%Cpp [concrete = imports.%Cpp] // CHECK:STDOUT: %unsigned_long.ref.loc24: type = name_ref unsigned_long, constants.%Cpp.unsigned_long [concrete = constants.%Cpp.unsigned_long] // CHECK:STDOUT: %impl.elem0.loc24_23.1: %.79d = impl_witness_access constants.%As.impl_witness, element0 [concrete = constants.%Core.IntLiteral.as.As.impl.Convert] // CHECK:STDOUT: %bound_method.loc24_23.1: = bound_method %int_1.loc24, %impl.elem0.loc24_23.1 [concrete = constants.%Core.IntLiteral.as.As.impl.Convert.bound] // CHECK:STDOUT: %Core.IntLiteral.as.As.impl.Convert.call: init %Cpp.unsigned_long = call %bound_method.loc24_23.1(%int_1.loc24) [concrete = constants.%int_1.0ab] // CHECK:STDOUT: %.loc24_23.1: %Cpp.unsigned_long = value_of_initializer %Core.IntLiteral.as.As.impl.Convert.call [concrete = constants.%int_1.0ab] // CHECK:STDOUT: %.loc24_23.2: %Cpp.unsigned_long = converted %int_1.loc24, %.loc24_23.1 [concrete = constants.%int_1.0ab] // CHECK:STDOUT: %impl.elem0.loc24_23.2: %.31b = impl_witness_access constants.%ImplicitAs.impl_witness.83c, element0 [concrete = constants.%Cpp.unsigned_long.as.ImplicitAs.impl.Convert.531] // CHECK:STDOUT: %bound_method.loc24_23.2: = bound_method %.loc24_23.2, %impl.elem0.loc24_23.2 [concrete = constants.%Cpp.unsigned_long.as.ImplicitAs.impl.Convert.bound] // CHECK:STDOUT: %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.call.loc24: init Core.IntLiteral = call %bound_method.loc24_23.2(%.loc24_23.2) [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %.loc24_23.3: Core.IntLiteral = value_of_initializer %Cpp.unsigned_long.as.ImplicitAs.impl.Convert.call.loc24 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %.loc24_23.4: Core.IntLiteral = converted %.loc24_23.2, %.loc24_23.3 [concrete = constants.%int_1.5b8] // CHECK:STDOUT: %array_type: type = array_type %.loc24_23.4, %f32 [concrete = constants.%array_type] // CHECK:STDOUT: } // CHECK:STDOUT: %a: ref %array_type = ref_binding a, %a.var // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.bound: = bound_method %a.var, constants.%DestroyT.binding.as_type.as.Destroy.impl.Op.9ec // CHECK:STDOUT: // CHECK:STDOUT: %bound_method.loc24_3: = bound_method %a.var, %DestroyT.binding.as_type.as.Destroy.impl.Op.specific_fn // CHECK:STDOUT: %DestroyT.binding.as_type.as.Destroy.impl.Op.call: init %empty_tuple.type = call %bound_method.loc24_3(%a.var) // CHECK:STDOUT: %UIntResult.cpp_destructor.bound: = bound_method %.loc22_67.3, constants.%UIntResult.cpp_destructor // CHECK:STDOUT: %UIntResult.cpp_destructor.call: init %empty_tuple.type = call %UIntResult.cpp_destructor.bound(%.loc22_67.3) // CHECK:STDOUT: %ULongResult.cpp_destructor.bound.loc19: = bound_method %.loc19_80.3, constants.%ULongResult.cpp_destructor // CHECK:STDOUT: %ULongResult.cpp_destructor.call.loc19: init %empty_tuple.type = call %ULongResult.cpp_destructor.bound.loc19(%.loc19_80.3) // CHECK:STDOUT: %ULongResult.cpp_destructor.bound.loc16: = bound_method %.loc16_82.3, constants.%ULongResult.cpp_destructor // CHECK:STDOUT: %ULongResult.cpp_destructor.call.loc16: init %empty_tuple.type = call %ULongResult.cpp_destructor.bound.loc16(%.loc16_82.3) // CHECK:STDOUT: // CHECK:STDOUT: } // CHECK:STDOUT: