assignment.carbon 35 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357
  1. // Part of the Carbon Language project, under the Apache License v2.0 with LLVM
  2. // Exceptions. See /LICENSE for license information.
  3. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  4. //
  5. // INCLUDE-FILE: toolchain/testing/testdata/min_prelude/int.carbon
  6. // TODO: Add ranges and switch to "--dump-sem-ir-ranges=only".
  7. // EXTRA-ARGS: --dump-sem-ir-ranges=if-present
  8. //
  9. // AUTOUPDATE
  10. // TIP: To test this file alone, run:
  11. // TIP: bazel test //toolchain/testing:file_test --test_arg=--file_tests=toolchain/check/testdata/operators/builtin/assignment.carbon
  12. // TIP: To dump output, run:
  13. // TIP: bazel run //toolchain/testing:file_test -- --dump_output --file_tests=toolchain/check/testdata/operators/builtin/assignment.carbon
  14. fn Main() {
  15. var a: i32 = 12;
  16. a = 9;
  17. var b: (i32, i32) = (1, 2);
  18. b.0 = 3;
  19. b.1 = 4;
  20. var c: {.a: i32, .b: i32} = {.a = 1, .b = 2};
  21. c.a = 3;
  22. c.b = 4;
  23. var p: i32* = &a;
  24. *p = 5;
  25. *(if true then p else &a) = 10;
  26. }
  27. // CHECK:STDOUT: --- assignment.carbon
  28. // CHECK:STDOUT:
  29. // CHECK:STDOUT: constants {
  30. // CHECK:STDOUT: %Main.type: type = fn_type @Main [concrete]
  31. // CHECK:STDOUT: %empty_tuple.type: type = tuple_type () [concrete]
  32. // CHECK:STDOUT: %Main: %Main.type = struct_value () [concrete]
  33. // CHECK:STDOUT: %int_32: Core.IntLiteral = int_value 32 [concrete]
  34. // CHECK:STDOUT: %Int.type: type = generic_class_type @Int [concrete]
  35. // CHECK:STDOUT: %Int.generic: %Int.type = struct_value () [concrete]
  36. // CHECK:STDOUT: %i32: type = class_type @Int, @Int(%int_32) [concrete]
  37. // CHECK:STDOUT: %pattern_type.7ce: type = pattern_type %i32 [concrete]
  38. // CHECK:STDOUT: %int_12.6a3: Core.IntLiteral = int_value 12 [concrete]
  39. // CHECK:STDOUT: %ImplicitAs.type.cc7: type = generic_interface_type @ImplicitAs [concrete]
  40. // CHECK:STDOUT: %ImplicitAs.generic: %ImplicitAs.type.cc7 = struct_value () [concrete]
  41. // CHECK:STDOUT: %ImplicitAs.type.e8c: type = facet_type <@ImplicitAs, @ImplicitAs(%i32)> [concrete]
  42. // CHECK:STDOUT: %ImplicitAs.Convert.type.1b6: type = fn_type @ImplicitAs.Convert, @ImplicitAs(%i32) [concrete]
  43. // CHECK:STDOUT: %To: Core.IntLiteral = bind_symbolic_name To, 0 [symbolic]
  44. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.49e: type = fn_type @Core.IntLiteral.as.ImplicitAs.impl.Convert, @Core.IntLiteral.as.ImplicitAs.impl(%To) [symbolic]
  45. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.f01: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.49e = struct_value () [symbolic]
  46. // CHECK:STDOUT: %ImplicitAs.impl_witness.acc: <witness> = impl_witness imports.%ImplicitAs.impl_witness_table.b6b, @Core.IntLiteral.as.ImplicitAs.impl(%int_32) [concrete]
  47. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.9ec: type = fn_type @Core.IntLiteral.as.ImplicitAs.impl.Convert, @Core.IntLiteral.as.ImplicitAs.impl(%int_32) [concrete]
  48. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.592: %Core.IntLiteral.as.ImplicitAs.impl.Convert.type.9ec = struct_value () [concrete]
  49. // CHECK:STDOUT: %ImplicitAs.facet: %ImplicitAs.type.e8c = facet_value Core.IntLiteral, (%ImplicitAs.impl_witness.acc) [concrete]
  50. // CHECK:STDOUT: %.7ea: type = fn_type_with_self_type %ImplicitAs.Convert.type.1b6, %ImplicitAs.facet [concrete]
  51. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.0b4: <bound method> = bound_method %int_12.6a3, %Core.IntLiteral.as.ImplicitAs.impl.Convert.592 [concrete]
  52. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn: <specific function> = specific_function %Core.IntLiteral.as.ImplicitAs.impl.Convert.592, @Core.IntLiteral.as.ImplicitAs.impl.Convert(%int_32) [concrete]
  53. // CHECK:STDOUT: %bound_method.827: <bound method> = bound_method %int_12.6a3, %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete]
  54. // CHECK:STDOUT: %int_12.1e1: %i32 = int_value 12 [concrete]
  55. // CHECK:STDOUT: %int_9.988: Core.IntLiteral = int_value 9 [concrete]
  56. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.025: <bound method> = bound_method %int_9.988, %Core.IntLiteral.as.ImplicitAs.impl.Convert.592 [concrete]
  57. // CHECK:STDOUT: %bound_method.da6: <bound method> = bound_method %int_9.988, %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete]
  58. // CHECK:STDOUT: %int_9.f88: %i32 = int_value 9 [concrete]
  59. // CHECK:STDOUT: %tuple.type.24b: type = tuple_type (type, type) [concrete]
  60. // CHECK:STDOUT: %tuple.type.d07: type = tuple_type (%i32, %i32) [concrete]
  61. // CHECK:STDOUT: %ptr.261: type = ptr_type %tuple.type.d07 [concrete]
  62. // CHECK:STDOUT: %pattern_type.511: type = pattern_type %tuple.type.d07 [concrete]
  63. // CHECK:STDOUT: %int_1.5b8: Core.IntLiteral = int_value 1 [concrete]
  64. // CHECK:STDOUT: %int_2.ecc: Core.IntLiteral = int_value 2 [concrete]
  65. // CHECK:STDOUT: %tuple.type.f94: type = tuple_type (Core.IntLiteral, Core.IntLiteral) [concrete]
  66. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.a02: <bound method> = bound_method %int_1.5b8, %Core.IntLiteral.as.ImplicitAs.impl.Convert.592 [concrete]
  67. // CHECK:STDOUT: %bound_method.b59: <bound method> = bound_method %int_1.5b8, %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete]
  68. // CHECK:STDOUT: %int_1.5d2: %i32 = int_value 1 [concrete]
  69. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.2d9: <bound method> = bound_method %int_2.ecc, %Core.IntLiteral.as.ImplicitAs.impl.Convert.592 [concrete]
  70. // CHECK:STDOUT: %bound_method.f6f: <bound method> = bound_method %int_2.ecc, %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete]
  71. // CHECK:STDOUT: %int_2.ef8: %i32 = int_value 2 [concrete]
  72. // CHECK:STDOUT: %tuple: %tuple.type.d07 = tuple_value (%int_1.5d2, %int_2.ef8) [concrete]
  73. // CHECK:STDOUT: %int_0: Core.IntLiteral = int_value 0 [concrete]
  74. // CHECK:STDOUT: %int_3.1ba: Core.IntLiteral = int_value 3 [concrete]
  75. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.c36: <bound method> = bound_method %int_3.1ba, %Core.IntLiteral.as.ImplicitAs.impl.Convert.592 [concrete]
  76. // CHECK:STDOUT: %bound_method.f79: <bound method> = bound_method %int_3.1ba, %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete]
  77. // CHECK:STDOUT: %int_3.822: %i32 = int_value 3 [concrete]
  78. // CHECK:STDOUT: %int_4.0c1: Core.IntLiteral = int_value 4 [concrete]
  79. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.121: <bound method> = bound_method %int_4.0c1, %Core.IntLiteral.as.ImplicitAs.impl.Convert.592 [concrete]
  80. // CHECK:STDOUT: %bound_method.564: <bound method> = bound_method %int_4.0c1, %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete]
  81. // CHECK:STDOUT: %int_4.940: %i32 = int_value 4 [concrete]
  82. // CHECK:STDOUT: %struct_type.a.b.501: type = struct_type {.a: %i32, .b: %i32} [concrete]
  83. // CHECK:STDOUT: %ptr.3ee: type = ptr_type %struct_type.a.b.501 [concrete]
  84. // CHECK:STDOUT: %pattern_type.851: type = pattern_type %struct_type.a.b.501 [concrete]
  85. // CHECK:STDOUT: %struct_type.a.b.cfd: type = struct_type {.a: Core.IntLiteral, .b: Core.IntLiteral} [concrete]
  86. // CHECK:STDOUT: %struct: %struct_type.a.b.501 = struct_value (%int_1.5d2, %int_2.ef8) [concrete]
  87. // CHECK:STDOUT: %ptr.235: type = ptr_type %i32 [concrete]
  88. // CHECK:STDOUT: %pattern_type.fe8: type = pattern_type %ptr.235 [concrete]
  89. // CHECK:STDOUT: %int_5.64b: Core.IntLiteral = int_value 5 [concrete]
  90. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.6c8: <bound method> = bound_method %int_5.64b, %Core.IntLiteral.as.ImplicitAs.impl.Convert.592 [concrete]
  91. // CHECK:STDOUT: %bound_method.918: <bound method> = bound_method %int_5.64b, %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete]
  92. // CHECK:STDOUT: %int_5.0f6: %i32 = int_value 5 [concrete]
  93. // CHECK:STDOUT: %true: bool = bool_literal true [concrete]
  94. // CHECK:STDOUT: %int_10.64f: Core.IntLiteral = int_value 10 [concrete]
  95. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.eb3: <bound method> = bound_method %int_10.64f, %Core.IntLiteral.as.ImplicitAs.impl.Convert.592 [concrete]
  96. // CHECK:STDOUT: %bound_method.dba: <bound method> = bound_method %int_10.64f, %Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn [concrete]
  97. // CHECK:STDOUT: %int_10.265: %i32 = int_value 10 [concrete]
  98. // CHECK:STDOUT: %Destroy.type: type = facet_type <@Destroy> [concrete]
  99. // CHECK:STDOUT: %T.as.Destroy.impl.Op.type.f2e: type = fn_type @T.as.Destroy.impl.Op, @T.as.Destroy.impl(%ptr.235) [concrete]
  100. // CHECK:STDOUT: %T.as.Destroy.impl.Op.fad: %T.as.Destroy.impl.Op.type.f2e = struct_value () [concrete]
  101. // CHECK:STDOUT: %ptr.5d5: type = ptr_type %ptr.235 [concrete]
  102. // CHECK:STDOUT: %T.as.Destroy.impl.Op.specific_fn.d25: <specific function> = specific_function %T.as.Destroy.impl.Op.fad, @T.as.Destroy.impl.Op(%ptr.235) [concrete]
  103. // CHECK:STDOUT: %T.as.Destroy.impl.Op.type.eb5: type = fn_type @T.as.Destroy.impl.Op, @T.as.Destroy.impl(%struct_type.a.b.501) [concrete]
  104. // CHECK:STDOUT: %T.as.Destroy.impl.Op.722: %T.as.Destroy.impl.Op.type.eb5 = struct_value () [concrete]
  105. // CHECK:STDOUT: %T.as.Destroy.impl.Op.specific_fn.e4c: <specific function> = specific_function %T.as.Destroy.impl.Op.722, @T.as.Destroy.impl.Op(%struct_type.a.b.501) [concrete]
  106. // CHECK:STDOUT: %T.as.Destroy.impl.Op.type.623: type = fn_type @T.as.Destroy.impl.Op, @T.as.Destroy.impl(%tuple.type.d07) [concrete]
  107. // CHECK:STDOUT: %T.as.Destroy.impl.Op.55d: %T.as.Destroy.impl.Op.type.623 = struct_value () [concrete]
  108. // CHECK:STDOUT: %T.as.Destroy.impl.Op.specific_fn.698: <specific function> = specific_function %T.as.Destroy.impl.Op.55d, @T.as.Destroy.impl.Op(%tuple.type.d07) [concrete]
  109. // CHECK:STDOUT: %Int.as.Destroy.impl.Op.type.11b: type = fn_type @Int.as.Destroy.impl.Op, @Int.as.Destroy.impl(%int_32) [concrete]
  110. // CHECK:STDOUT: %Int.as.Destroy.impl.Op.054: %Int.as.Destroy.impl.Op.type.11b = struct_value () [concrete]
  111. // CHECK:STDOUT: %Int.as.Destroy.impl.Op.specific_fn: <specific function> = specific_function %Int.as.Destroy.impl.Op.054, @Int.as.Destroy.impl.Op(%int_32) [concrete]
  112. // CHECK:STDOUT: }
  113. // CHECK:STDOUT:
  114. // CHECK:STDOUT: imports {
  115. // CHECK:STDOUT: %Core: <namespace> = namespace file.%Core.import, [concrete] {
  116. // CHECK:STDOUT: .Int = %Core.Int
  117. // CHECK:STDOUT: .ImplicitAs = %Core.ImplicitAs
  118. // CHECK:STDOUT: .Destroy = %Core.Destroy
  119. // CHECK:STDOUT: import Core//prelude
  120. // CHECK:STDOUT: import Core//prelude/...
  121. // CHECK:STDOUT: }
  122. // CHECK:STDOUT: %Core.Int: %Int.type = import_ref Core//prelude/parts/int, Int, loaded [concrete = constants.%Int.generic]
  123. // CHECK:STDOUT: %Core.ImplicitAs: %ImplicitAs.type.cc7 = import_ref Core//prelude/parts/as, ImplicitAs, loaded [concrete = constants.%ImplicitAs.generic]
  124. // CHECK:STDOUT: %Core.import_ref.428: @Core.IntLiteral.as.ImplicitAs.impl.%Core.IntLiteral.as.ImplicitAs.impl.Convert.type (%Core.IntLiteral.as.ImplicitAs.impl.Convert.type.49e) = import_ref Core//prelude/parts/int, loc16_39, loaded [symbolic = @Core.IntLiteral.as.ImplicitAs.impl.%Core.IntLiteral.as.ImplicitAs.impl.Convert (constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.f01)]
  125. // CHECK:STDOUT: %ImplicitAs.impl_witness_table.b6b = impl_witness_table (%Core.import_ref.428), @Core.IntLiteral.as.ImplicitAs.impl [concrete]
  126. // CHECK:STDOUT: %Core.Destroy: type = import_ref Core//prelude/parts/destroy, Destroy, loaded [concrete = constants.%Destroy.type]
  127. // CHECK:STDOUT: }
  128. // CHECK:STDOUT:
  129. // CHECK:STDOUT: file {
  130. // CHECK:STDOUT: package: <namespace> = namespace [concrete] {
  131. // CHECK:STDOUT: .Core = imports.%Core
  132. // CHECK:STDOUT: .Main = %Main.decl
  133. // CHECK:STDOUT: }
  134. // CHECK:STDOUT: %Core.import = import Core
  135. // CHECK:STDOUT: %Main.decl: %Main.type = fn_decl @Main [concrete = constants.%Main] {} {}
  136. // CHECK:STDOUT: }
  137. // CHECK:STDOUT:
  138. // CHECK:STDOUT: fn @Main() {
  139. // CHECK:STDOUT: !entry:
  140. // CHECK:STDOUT: name_binding_decl {
  141. // CHECK:STDOUT: %a.patt: %pattern_type.7ce = binding_pattern a [concrete]
  142. // CHECK:STDOUT: %a.var_patt: %pattern_type.7ce = var_pattern %a.patt [concrete]
  143. // CHECK:STDOUT: }
  144. // CHECK:STDOUT: %a.var: ref %i32 = var %a.var_patt
  145. // CHECK:STDOUT: %int_12: Core.IntLiteral = int_value 12 [concrete = constants.%int_12.6a3]
  146. // CHECK:STDOUT: %impl.elem0.loc16: %.7ea = impl_witness_access constants.%ImplicitAs.impl_witness.acc, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.592]
  147. // CHECK:STDOUT: %bound_method.loc16_3.1: <bound method> = bound_method %int_12, %impl.elem0.loc16 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.0b4]
  148. // CHECK:STDOUT: %specific_fn.loc16: <specific function> = specific_function %impl.elem0.loc16, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn]
  149. // CHECK:STDOUT: %bound_method.loc16_3.2: <bound method> = bound_method %int_12, %specific_fn.loc16 [concrete = constants.%bound_method.827]
  150. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc16: init %i32 = call %bound_method.loc16_3.2(%int_12) [concrete = constants.%int_12.1e1]
  151. // CHECK:STDOUT: %.loc16_3: init %i32 = converted %int_12, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc16 [concrete = constants.%int_12.1e1]
  152. // CHECK:STDOUT: assign %a.var, %.loc16_3
  153. // CHECK:STDOUT: %.loc16_10: type = splice_block %i32.loc16 [concrete = constants.%i32] {
  154. // CHECK:STDOUT: %int_32.loc16: Core.IntLiteral = int_value 32 [concrete = constants.%int_32]
  155. // CHECK:STDOUT: %i32.loc16: type = class_type @Int, @Int(constants.%int_32) [concrete = constants.%i32]
  156. // CHECK:STDOUT: }
  157. // CHECK:STDOUT: %a: ref %i32 = bind_name a, %a.var
  158. // CHECK:STDOUT: %a.ref.loc17: ref %i32 = name_ref a, %a
  159. // CHECK:STDOUT: %int_9: Core.IntLiteral = int_value 9 [concrete = constants.%int_9.988]
  160. // CHECK:STDOUT: %impl.elem0.loc17: %.7ea = impl_witness_access constants.%ImplicitAs.impl_witness.acc, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.592]
  161. // CHECK:STDOUT: %bound_method.loc17_5.1: <bound method> = bound_method %int_9, %impl.elem0.loc17 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.025]
  162. // CHECK:STDOUT: %specific_fn.loc17: <specific function> = specific_function %impl.elem0.loc17, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn]
  163. // CHECK:STDOUT: %bound_method.loc17_5.2: <bound method> = bound_method %int_9, %specific_fn.loc17 [concrete = constants.%bound_method.da6]
  164. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc17: init %i32 = call %bound_method.loc17_5.2(%int_9) [concrete = constants.%int_9.f88]
  165. // CHECK:STDOUT: %.loc17: init %i32 = converted %int_9, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc17 [concrete = constants.%int_9.f88]
  166. // CHECK:STDOUT: assign %a.ref.loc17, %.loc17
  167. // CHECK:STDOUT: name_binding_decl {
  168. // CHECK:STDOUT: %b.patt: %pattern_type.511 = binding_pattern b [concrete]
  169. // CHECK:STDOUT: %b.var_patt: %pattern_type.511 = var_pattern %b.patt [concrete]
  170. // CHECK:STDOUT: }
  171. // CHECK:STDOUT: %b.var: ref %tuple.type.d07 = var %b.var_patt
  172. // CHECK:STDOUT: %int_1.loc19: Core.IntLiteral = int_value 1 [concrete = constants.%int_1.5b8]
  173. // CHECK:STDOUT: %int_2.loc19: Core.IntLiteral = int_value 2 [concrete = constants.%int_2.ecc]
  174. // CHECK:STDOUT: %.loc19_28.1: %tuple.type.f94 = tuple_literal (%int_1.loc19, %int_2.loc19)
  175. // CHECK:STDOUT: %impl.elem0.loc19_28.1: %.7ea = impl_witness_access constants.%ImplicitAs.impl_witness.acc, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.592]
  176. // CHECK:STDOUT: %bound_method.loc19_28.1: <bound method> = bound_method %int_1.loc19, %impl.elem0.loc19_28.1 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.a02]
  177. // CHECK:STDOUT: %specific_fn.loc19_28.1: <specific function> = specific_function %impl.elem0.loc19_28.1, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn]
  178. // CHECK:STDOUT: %bound_method.loc19_28.2: <bound method> = bound_method %int_1.loc19, %specific_fn.loc19_28.1 [concrete = constants.%bound_method.b59]
  179. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc19_28.1: init %i32 = call %bound_method.loc19_28.2(%int_1.loc19) [concrete = constants.%int_1.5d2]
  180. // CHECK:STDOUT: %.loc19_28.2: init %i32 = converted %int_1.loc19, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc19_28.1 [concrete = constants.%int_1.5d2]
  181. // CHECK:STDOUT: %tuple.elem0.loc19: ref %i32 = tuple_access %b.var, element0
  182. // CHECK:STDOUT: %.loc19_28.3: init %i32 = initialize_from %.loc19_28.2 to %tuple.elem0.loc19 [concrete = constants.%int_1.5d2]
  183. // CHECK:STDOUT: %impl.elem0.loc19_28.2: %.7ea = impl_witness_access constants.%ImplicitAs.impl_witness.acc, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.592]
  184. // CHECK:STDOUT: %bound_method.loc19_28.3: <bound method> = bound_method %int_2.loc19, %impl.elem0.loc19_28.2 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.2d9]
  185. // CHECK:STDOUT: %specific_fn.loc19_28.2: <specific function> = specific_function %impl.elem0.loc19_28.2, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn]
  186. // CHECK:STDOUT: %bound_method.loc19_28.4: <bound method> = bound_method %int_2.loc19, %specific_fn.loc19_28.2 [concrete = constants.%bound_method.f6f]
  187. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc19_28.2: init %i32 = call %bound_method.loc19_28.4(%int_2.loc19) [concrete = constants.%int_2.ef8]
  188. // CHECK:STDOUT: %.loc19_28.4: init %i32 = converted %int_2.loc19, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc19_28.2 [concrete = constants.%int_2.ef8]
  189. // CHECK:STDOUT: %tuple.elem1.loc19: ref %i32 = tuple_access %b.var, element1
  190. // CHECK:STDOUT: %.loc19_28.5: init %i32 = initialize_from %.loc19_28.4 to %tuple.elem1.loc19 [concrete = constants.%int_2.ef8]
  191. // CHECK:STDOUT: %.loc19_28.6: init %tuple.type.d07 = tuple_init (%.loc19_28.3, %.loc19_28.5) to %b.var [concrete = constants.%tuple]
  192. // CHECK:STDOUT: %.loc19_3: init %tuple.type.d07 = converted %.loc19_28.1, %.loc19_28.6 [concrete = constants.%tuple]
  193. // CHECK:STDOUT: assign %b.var, %.loc19_3
  194. // CHECK:STDOUT: %.loc19_19.1: type = splice_block %.loc19_19.3 [concrete = constants.%tuple.type.d07] {
  195. // CHECK:STDOUT: %int_32.loc19_11: Core.IntLiteral = int_value 32 [concrete = constants.%int_32]
  196. // CHECK:STDOUT: %i32.loc19_11: type = class_type @Int, @Int(constants.%int_32) [concrete = constants.%i32]
  197. // CHECK:STDOUT: %int_32.loc19_16: Core.IntLiteral = int_value 32 [concrete = constants.%int_32]
  198. // CHECK:STDOUT: %i32.loc19_16: type = class_type @Int, @Int(constants.%int_32) [concrete = constants.%i32]
  199. // CHECK:STDOUT: %.loc19_19.2: %tuple.type.24b = tuple_literal (%i32.loc19_11, %i32.loc19_16)
  200. // CHECK:STDOUT: %.loc19_19.3: type = converted %.loc19_19.2, constants.%tuple.type.d07 [concrete = constants.%tuple.type.d07]
  201. // CHECK:STDOUT: }
  202. // CHECK:STDOUT: %b: ref %tuple.type.d07 = bind_name b, %b.var
  203. // CHECK:STDOUT: %b.ref.loc20: ref %tuple.type.d07 = name_ref b, %b
  204. // CHECK:STDOUT: %int_0: Core.IntLiteral = int_value 0 [concrete = constants.%int_0]
  205. // CHECK:STDOUT: %tuple.elem0.loc20: ref %i32 = tuple_access %b.ref.loc20, element0
  206. // CHECK:STDOUT: %int_3.loc20: Core.IntLiteral = int_value 3 [concrete = constants.%int_3.1ba]
  207. // CHECK:STDOUT: %impl.elem0.loc20: %.7ea = impl_witness_access constants.%ImplicitAs.impl_witness.acc, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.592]
  208. // CHECK:STDOUT: %bound_method.loc20_7.1: <bound method> = bound_method %int_3.loc20, %impl.elem0.loc20 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.c36]
  209. // CHECK:STDOUT: %specific_fn.loc20: <specific function> = specific_function %impl.elem0.loc20, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn]
  210. // CHECK:STDOUT: %bound_method.loc20_7.2: <bound method> = bound_method %int_3.loc20, %specific_fn.loc20 [concrete = constants.%bound_method.f79]
  211. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc20: init %i32 = call %bound_method.loc20_7.2(%int_3.loc20) [concrete = constants.%int_3.822]
  212. // CHECK:STDOUT: %.loc20: init %i32 = converted %int_3.loc20, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc20 [concrete = constants.%int_3.822]
  213. // CHECK:STDOUT: assign %tuple.elem0.loc20, %.loc20
  214. // CHECK:STDOUT: %b.ref.loc21: ref %tuple.type.d07 = name_ref b, %b
  215. // CHECK:STDOUT: %int_1.loc21: Core.IntLiteral = int_value 1 [concrete = constants.%int_1.5b8]
  216. // CHECK:STDOUT: %tuple.elem1.loc21: ref %i32 = tuple_access %b.ref.loc21, element1
  217. // CHECK:STDOUT: %int_4.loc21: Core.IntLiteral = int_value 4 [concrete = constants.%int_4.0c1]
  218. // CHECK:STDOUT: %impl.elem0.loc21: %.7ea = impl_witness_access constants.%ImplicitAs.impl_witness.acc, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.592]
  219. // CHECK:STDOUT: %bound_method.loc21_7.1: <bound method> = bound_method %int_4.loc21, %impl.elem0.loc21 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.121]
  220. // CHECK:STDOUT: %specific_fn.loc21: <specific function> = specific_function %impl.elem0.loc21, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn]
  221. // CHECK:STDOUT: %bound_method.loc21_7.2: <bound method> = bound_method %int_4.loc21, %specific_fn.loc21 [concrete = constants.%bound_method.564]
  222. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc21: init %i32 = call %bound_method.loc21_7.2(%int_4.loc21) [concrete = constants.%int_4.940]
  223. // CHECK:STDOUT: %.loc21: init %i32 = converted %int_4.loc21, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc21 [concrete = constants.%int_4.940]
  224. // CHECK:STDOUT: assign %tuple.elem1.loc21, %.loc21
  225. // CHECK:STDOUT: name_binding_decl {
  226. // CHECK:STDOUT: %c.patt: %pattern_type.851 = binding_pattern c [concrete]
  227. // CHECK:STDOUT: %c.var_patt: %pattern_type.851 = var_pattern %c.patt [concrete]
  228. // CHECK:STDOUT: }
  229. // CHECK:STDOUT: %c.var: ref %struct_type.a.b.501 = var %c.var_patt
  230. // CHECK:STDOUT: %int_1.loc23: Core.IntLiteral = int_value 1 [concrete = constants.%int_1.5b8]
  231. // CHECK:STDOUT: %int_2.loc23: Core.IntLiteral = int_value 2 [concrete = constants.%int_2.ecc]
  232. // CHECK:STDOUT: %.loc23_46.1: %struct_type.a.b.cfd = struct_literal (%int_1.loc23, %int_2.loc23)
  233. // CHECK:STDOUT: %impl.elem0.loc23_46.1: %.7ea = impl_witness_access constants.%ImplicitAs.impl_witness.acc, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.592]
  234. // CHECK:STDOUT: %bound_method.loc23_46.1: <bound method> = bound_method %int_1.loc23, %impl.elem0.loc23_46.1 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.a02]
  235. // CHECK:STDOUT: %specific_fn.loc23_46.1: <specific function> = specific_function %impl.elem0.loc23_46.1, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn]
  236. // CHECK:STDOUT: %bound_method.loc23_46.2: <bound method> = bound_method %int_1.loc23, %specific_fn.loc23_46.1 [concrete = constants.%bound_method.b59]
  237. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc23_46.1: init %i32 = call %bound_method.loc23_46.2(%int_1.loc23) [concrete = constants.%int_1.5d2]
  238. // CHECK:STDOUT: %.loc23_46.2: init %i32 = converted %int_1.loc23, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc23_46.1 [concrete = constants.%int_1.5d2]
  239. // CHECK:STDOUT: %.loc23_46.3: ref %i32 = struct_access %c.var, element0
  240. // CHECK:STDOUT: %.loc23_46.4: init %i32 = initialize_from %.loc23_46.2 to %.loc23_46.3 [concrete = constants.%int_1.5d2]
  241. // CHECK:STDOUT: %impl.elem0.loc23_46.2: %.7ea = impl_witness_access constants.%ImplicitAs.impl_witness.acc, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.592]
  242. // CHECK:STDOUT: %bound_method.loc23_46.3: <bound method> = bound_method %int_2.loc23, %impl.elem0.loc23_46.2 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.2d9]
  243. // CHECK:STDOUT: %specific_fn.loc23_46.2: <specific function> = specific_function %impl.elem0.loc23_46.2, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn]
  244. // CHECK:STDOUT: %bound_method.loc23_46.4: <bound method> = bound_method %int_2.loc23, %specific_fn.loc23_46.2 [concrete = constants.%bound_method.f6f]
  245. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc23_46.2: init %i32 = call %bound_method.loc23_46.4(%int_2.loc23) [concrete = constants.%int_2.ef8]
  246. // CHECK:STDOUT: %.loc23_46.5: init %i32 = converted %int_2.loc23, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc23_46.2 [concrete = constants.%int_2.ef8]
  247. // CHECK:STDOUT: %.loc23_46.6: ref %i32 = struct_access %c.var, element1
  248. // CHECK:STDOUT: %.loc23_46.7: init %i32 = initialize_from %.loc23_46.5 to %.loc23_46.6 [concrete = constants.%int_2.ef8]
  249. // CHECK:STDOUT: %.loc23_46.8: init %struct_type.a.b.501 = struct_init (%.loc23_46.4, %.loc23_46.7) to %c.var [concrete = constants.%struct]
  250. // CHECK:STDOUT: %.loc23_3: init %struct_type.a.b.501 = converted %.loc23_46.1, %.loc23_46.8 [concrete = constants.%struct]
  251. // CHECK:STDOUT: assign %c.var, %.loc23_3
  252. // CHECK:STDOUT: %.loc23_27: type = splice_block %struct_type.a.b [concrete = constants.%struct_type.a.b.501] {
  253. // CHECK:STDOUT: %int_32.loc23_15: Core.IntLiteral = int_value 32 [concrete = constants.%int_32]
  254. // CHECK:STDOUT: %i32.loc23_15: type = class_type @Int, @Int(constants.%int_32) [concrete = constants.%i32]
  255. // CHECK:STDOUT: %int_32.loc23_24: Core.IntLiteral = int_value 32 [concrete = constants.%int_32]
  256. // CHECK:STDOUT: %i32.loc23_24: type = class_type @Int, @Int(constants.%int_32) [concrete = constants.%i32]
  257. // CHECK:STDOUT: %struct_type.a.b: type = struct_type {.a: %i32, .b: %i32} [concrete = constants.%struct_type.a.b.501]
  258. // CHECK:STDOUT: }
  259. // CHECK:STDOUT: %c: ref %struct_type.a.b.501 = bind_name c, %c.var
  260. // CHECK:STDOUT: %c.ref.loc24: ref %struct_type.a.b.501 = name_ref c, %c
  261. // CHECK:STDOUT: %.loc24_4: ref %i32 = struct_access %c.ref.loc24, element0
  262. // CHECK:STDOUT: %int_3.loc24: Core.IntLiteral = int_value 3 [concrete = constants.%int_3.1ba]
  263. // CHECK:STDOUT: %impl.elem0.loc24: %.7ea = impl_witness_access constants.%ImplicitAs.impl_witness.acc, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.592]
  264. // CHECK:STDOUT: %bound_method.loc24_7.1: <bound method> = bound_method %int_3.loc24, %impl.elem0.loc24 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.c36]
  265. // CHECK:STDOUT: %specific_fn.loc24: <specific function> = specific_function %impl.elem0.loc24, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn]
  266. // CHECK:STDOUT: %bound_method.loc24_7.2: <bound method> = bound_method %int_3.loc24, %specific_fn.loc24 [concrete = constants.%bound_method.f79]
  267. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc24: init %i32 = call %bound_method.loc24_7.2(%int_3.loc24) [concrete = constants.%int_3.822]
  268. // CHECK:STDOUT: %.loc24_7: init %i32 = converted %int_3.loc24, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc24 [concrete = constants.%int_3.822]
  269. // CHECK:STDOUT: assign %.loc24_4, %.loc24_7
  270. // CHECK:STDOUT: %c.ref.loc25: ref %struct_type.a.b.501 = name_ref c, %c
  271. // CHECK:STDOUT: %.loc25_4: ref %i32 = struct_access %c.ref.loc25, element1
  272. // CHECK:STDOUT: %int_4.loc25: Core.IntLiteral = int_value 4 [concrete = constants.%int_4.0c1]
  273. // CHECK:STDOUT: %impl.elem0.loc25: %.7ea = impl_witness_access constants.%ImplicitAs.impl_witness.acc, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.592]
  274. // CHECK:STDOUT: %bound_method.loc25_7.1: <bound method> = bound_method %int_4.loc25, %impl.elem0.loc25 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.121]
  275. // CHECK:STDOUT: %specific_fn.loc25: <specific function> = specific_function %impl.elem0.loc25, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn]
  276. // CHECK:STDOUT: %bound_method.loc25_7.2: <bound method> = bound_method %int_4.loc25, %specific_fn.loc25 [concrete = constants.%bound_method.564]
  277. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc25: init %i32 = call %bound_method.loc25_7.2(%int_4.loc25) [concrete = constants.%int_4.940]
  278. // CHECK:STDOUT: %.loc25_7: init %i32 = converted %int_4.loc25, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc25 [concrete = constants.%int_4.940]
  279. // CHECK:STDOUT: assign %.loc25_4, %.loc25_7
  280. // CHECK:STDOUT: name_binding_decl {
  281. // CHECK:STDOUT: %p.patt: %pattern_type.fe8 = binding_pattern p [concrete]
  282. // CHECK:STDOUT: %p.var_patt: %pattern_type.fe8 = var_pattern %p.patt [concrete]
  283. // CHECK:STDOUT: }
  284. // CHECK:STDOUT: %p.var: ref %ptr.235 = var %p.var_patt
  285. // CHECK:STDOUT: %a.ref.loc27: ref %i32 = name_ref a, %a
  286. // CHECK:STDOUT: %addr.loc27_17: %ptr.235 = addr_of %a.ref.loc27
  287. // CHECK:STDOUT: assign %p.var, %addr.loc27_17
  288. // CHECK:STDOUT: %.loc27: type = splice_block %ptr [concrete = constants.%ptr.235] {
  289. // CHECK:STDOUT: %int_32.loc27: Core.IntLiteral = int_value 32 [concrete = constants.%int_32]
  290. // CHECK:STDOUT: %i32.loc27: type = class_type @Int, @Int(constants.%int_32) [concrete = constants.%i32]
  291. // CHECK:STDOUT: %ptr: type = ptr_type %i32.loc27 [concrete = constants.%ptr.235]
  292. // CHECK:STDOUT: }
  293. // CHECK:STDOUT: %p: ref %ptr.235 = bind_name p, %p.var
  294. // CHECK:STDOUT: %p.ref.loc28: ref %ptr.235 = name_ref p, %p
  295. // CHECK:STDOUT: %.loc28_4: %ptr.235 = bind_value %p.ref.loc28
  296. // CHECK:STDOUT: %.loc28_3: ref %i32 = deref %.loc28_4
  297. // CHECK:STDOUT: %int_5: Core.IntLiteral = int_value 5 [concrete = constants.%int_5.64b]
  298. // CHECK:STDOUT: %impl.elem0.loc28: %.7ea = impl_witness_access constants.%ImplicitAs.impl_witness.acc, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.592]
  299. // CHECK:STDOUT: %bound_method.loc28_6.1: <bound method> = bound_method %int_5, %impl.elem0.loc28 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.6c8]
  300. // CHECK:STDOUT: %specific_fn.loc28: <specific function> = specific_function %impl.elem0.loc28, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn]
  301. // CHECK:STDOUT: %bound_method.loc28_6.2: <bound method> = bound_method %int_5, %specific_fn.loc28 [concrete = constants.%bound_method.918]
  302. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc28: init %i32 = call %bound_method.loc28_6.2(%int_5) [concrete = constants.%int_5.0f6]
  303. // CHECK:STDOUT: %.loc28_6: init %i32 = converted %int_5, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc28 [concrete = constants.%int_5.0f6]
  304. // CHECK:STDOUT: assign %.loc28_3, %.loc28_6
  305. // CHECK:STDOUT: %true: bool = bool_literal true [concrete = constants.%true]
  306. // CHECK:STDOUT: if %true br !if.expr.then else br !if.expr.else
  307. // CHECK:STDOUT:
  308. // CHECK:STDOUT: !if.expr.then:
  309. // CHECK:STDOUT: %p.ref.loc30: ref %ptr.235 = name_ref p, %p
  310. // CHECK:STDOUT: %.loc30_18: %ptr.235 = bind_value %p.ref.loc30
  311. // CHECK:STDOUT: br !if.expr.result(%.loc30_18)
  312. // CHECK:STDOUT:
  313. // CHECK:STDOUT: !if.expr.else:
  314. // CHECK:STDOUT: %a.ref.loc30: ref %i32 = name_ref a, %a
  315. // CHECK:STDOUT: %addr.loc30: %ptr.235 = addr_of %a.ref.loc30
  316. // CHECK:STDOUT: br !if.expr.result(%addr.loc30)
  317. // CHECK:STDOUT:
  318. // CHECK:STDOUT: !if.expr.result:
  319. // CHECK:STDOUT: %.loc30_5: %ptr.235 = block_arg !if.expr.result
  320. // CHECK:STDOUT: %.loc30_3: ref %i32 = deref %.loc30_5
  321. // CHECK:STDOUT: %int_10: Core.IntLiteral = int_value 10 [concrete = constants.%int_10.64f]
  322. // CHECK:STDOUT: %impl.elem0.loc30: %.7ea = impl_witness_access constants.%ImplicitAs.impl_witness.acc, element0 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.592]
  323. // CHECK:STDOUT: %bound_method.loc30_29.1: <bound method> = bound_method %int_10, %impl.elem0.loc30 [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.bound.eb3]
  324. // CHECK:STDOUT: %specific_fn.loc30: <specific function> = specific_function %impl.elem0.loc30, @Core.IntLiteral.as.ImplicitAs.impl.Convert(constants.%int_32) [concrete = constants.%Core.IntLiteral.as.ImplicitAs.impl.Convert.specific_fn]
  325. // CHECK:STDOUT: %bound_method.loc30_29.2: <bound method> = bound_method %int_10, %specific_fn.loc30 [concrete = constants.%bound_method.dba]
  326. // CHECK:STDOUT: %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc30: init %i32 = call %bound_method.loc30_29.2(%int_10) [concrete = constants.%int_10.265]
  327. // CHECK:STDOUT: %.loc30_29: init %i32 = converted %int_10, %Core.IntLiteral.as.ImplicitAs.impl.Convert.call.loc30 [concrete = constants.%int_10.265]
  328. // CHECK:STDOUT: assign %.loc30_3, %.loc30_29
  329. // CHECK:STDOUT: %T.as.Destroy.impl.Op.bound.loc27: <bound method> = bound_method %p.var, constants.%T.as.Destroy.impl.Op.fad
  330. // CHECK:STDOUT: %T.as.Destroy.impl.Op.specific_fn.1: <specific function> = specific_function constants.%T.as.Destroy.impl.Op.fad, @T.as.Destroy.impl.Op(constants.%ptr.235) [concrete = constants.%T.as.Destroy.impl.Op.specific_fn.d25]
  331. // CHECK:STDOUT: %bound_method.loc27: <bound method> = bound_method %p.var, %T.as.Destroy.impl.Op.specific_fn.1
  332. // CHECK:STDOUT: %addr.loc27_3: %ptr.5d5 = addr_of %p.var
  333. // CHECK:STDOUT: %T.as.Destroy.impl.Op.call.loc27: init %empty_tuple.type = call %bound_method.loc27(%addr.loc27_3)
  334. // CHECK:STDOUT: %T.as.Destroy.impl.Op.bound.loc23: <bound method> = bound_method %c.var, constants.%T.as.Destroy.impl.Op.722
  335. // CHECK:STDOUT: %T.as.Destroy.impl.Op.specific_fn.2: <specific function> = specific_function constants.%T.as.Destroy.impl.Op.722, @T.as.Destroy.impl.Op(constants.%struct_type.a.b.501) [concrete = constants.%T.as.Destroy.impl.Op.specific_fn.e4c]
  336. // CHECK:STDOUT: %bound_method.loc23_3: <bound method> = bound_method %c.var, %T.as.Destroy.impl.Op.specific_fn.2
  337. // CHECK:STDOUT: %addr.loc23: %ptr.3ee = addr_of %c.var
  338. // CHECK:STDOUT: %T.as.Destroy.impl.Op.call.loc23: init %empty_tuple.type = call %bound_method.loc23_3(%addr.loc23)
  339. // CHECK:STDOUT: %T.as.Destroy.impl.Op.bound.loc19: <bound method> = bound_method %b.var, constants.%T.as.Destroy.impl.Op.55d
  340. // CHECK:STDOUT: %T.as.Destroy.impl.Op.specific_fn.3: <specific function> = specific_function constants.%T.as.Destroy.impl.Op.55d, @T.as.Destroy.impl.Op(constants.%tuple.type.d07) [concrete = constants.%T.as.Destroy.impl.Op.specific_fn.698]
  341. // CHECK:STDOUT: %bound_method.loc19_3: <bound method> = bound_method %b.var, %T.as.Destroy.impl.Op.specific_fn.3
  342. // CHECK:STDOUT: %addr.loc19: %ptr.261 = addr_of %b.var
  343. // CHECK:STDOUT: %T.as.Destroy.impl.Op.call.loc19: init %empty_tuple.type = call %bound_method.loc19_3(%addr.loc19)
  344. // CHECK:STDOUT: %Int.as.Destroy.impl.Op.bound: <bound method> = bound_method %a.var, constants.%Int.as.Destroy.impl.Op.054
  345. // CHECK:STDOUT: %Int.as.Destroy.impl.Op.specific_fn: <specific function> = specific_function constants.%Int.as.Destroy.impl.Op.054, @Int.as.Destroy.impl.Op(constants.%int_32) [concrete = constants.%Int.as.Destroy.impl.Op.specific_fn]
  346. // CHECK:STDOUT: %bound_method.loc16_3.3: <bound method> = bound_method %a.var, %Int.as.Destroy.impl.Op.specific_fn
  347. // CHECK:STDOUT: %addr.loc16: %ptr.235 = addr_of %a.var
  348. // CHECK:STDOUT: %Int.as.Destroy.impl.Op.call: init %empty_tuple.type = call %bound_method.loc16_3.3(%addr.loc16)
  349. // CHECK:STDOUT: return
  350. // CHECK:STDOUT: }
  351. // CHECK:STDOUT: