Created
August 18, 2025 21:05
-
-
Save hmlongco/0f048c98f0c3e3b0ae9f0c5c809cbc17 to your computer and use it in GitHub Desktop.
ObservationIgnoredImpacts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sil_stage canonical | |
import Builtin | |
import Swift | |
import SwiftShims | |
import Observation | |
class ViewModel { | |
@_hasStorage @_hasInitialValue private var _name: String { get set } | |
@_hasInitialValue var name: String { | |
@storageRestrictions(initializes: _name) init(initialValue) | |
get | |
set | |
_modify | |
} | |
@_hasStorage @_hasInitialValue private var _title: String { get set } | |
@_hasInitialValue var title: String { | |
@storageRestrictions(initializes: _title) init(initialValue) | |
get | |
set | |
_modify | |
} | |
@_hasStorage @_hasInitialValue var ignored: Bool { get set } | |
@_hasStorage @_hasInitialValue private var _hasBoilerplate: Bool { get set } | |
@_hasInitialValue private var hasBoilerplate: Bool { | |
@storageRestrictions(initializes: _hasBoilerplate) init(initialValue) | |
get | |
set | |
_modify | |
} | |
@_hasStorage @_hasInitialValue private final let _$observationRegistrar: ObservationRegistrar { get } | |
internal nonisolated func access<Member>(keyPath: KeyPath<ViewModel, Member>) | |
internal nonisolated func withMutation<Member, MutationResult>(keyPath: KeyPath<ViewModel, Member>, _ mutation: () throws -> MutationResult) rethrows -> MutationResult | |
@objc deinit | |
init() | |
} | |
extension ViewModel : Observable { | |
} | |
// main | |
// Isolation: unspecified | |
sil @main : $@convention(c) (Int32, UnsafeMutablePointer<Optional<UnsafeMutablePointer<Int8>>>) -> Int32 { | |
bb0(%0 : $Int32, %1 : $UnsafeMutablePointer<Optional<UnsafeMutablePointer<Int8>>>): | |
%2 = integer_literal $Builtin.Int32, 0 // user: %3 | |
%3 = struct $Int32 (%2 : $Builtin.Int32) // user: %4 | |
return %3 : $Int32 // id: %4 | |
} // end sil function 'main' | |
// variable initialization expression of ViewModel.name | |
// Isolation: unspecified | |
sil hidden [transparent] @$s9ViewModelAAC4nameSSvpfi : $@convention(thin) () -> @owned String { | |
bb0: | |
%0 = string_literal utf8 "Michael Long" // user: %5 | |
%1 = integer_literal $Builtin.Word, 12 // user: %5 | |
%2 = integer_literal $Builtin.Int1, -1 // user: %5 | |
%3 = metatype $@thin String.Type // user: %5 | |
// function_ref String.init(_builtinStringLiteral:utf8CodeUnitCount:isASCII:) | |
%4 = function_ref @$sSS21_builtinStringLiteral17utf8CodeUnitCount7isASCIISSBp_BwBi1_tcfC : $@convention(method) (Builtin.RawPointer, Builtin.Word, Builtin.Int1, @thin String.Type) -> @owned String // user: %5 | |
%5 = apply %4(%0, %1, %2, %3) : $@convention(method) (Builtin.RawPointer, Builtin.Word, Builtin.Int1, @thin String.Type) -> @owned String // user: %6 | |
return %5 : $String // id: %6 | |
} // end sil function '$s9ViewModelAAC4nameSSvpfi' | |
// String.init(_builtinStringLiteral:utf8CodeUnitCount:isASCII:) | |
// Isolation: unspecified | |
sil [always_inline] [readonly] [_semantics "string.makeUTF8"] @$sSS21_builtinStringLiteral17utf8CodeUnitCount7isASCIISSBp_BwBi1_tcfC : $@convention(method) (Builtin.RawPointer, Builtin.Word, Builtin.Int1, @thin String.Type) -> @owned String | |
// ViewModel._name.getter | |
// Isolation: unspecified | |
sil private [transparent] @$s9ViewModelAAC5_name33_1E59A94D38984979103BAB9BD1543592LLSSvg : $@convention(method) (@guaranteed ViewModel) -> @owned String { | |
// %0 "self" // users: %2, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = ref_element_addr %0 : $ViewModel, #ViewModel._name // user: %3 | |
%3 = begin_access [read] [dynamic] %2 : $*String // users: %4, %6 | |
%4 = load %3 : $*String // users: %7, %5 | |
retain_value %4 : $String // id: %5 | |
end_access %3 : $*String // id: %6 | |
return %4 : $String // id: %7 | |
} // end sil function '$s9ViewModelAAC5_name33_1E59A94D38984979103BAB9BD1543592LLSSvg' | |
// ViewModel._name.setter | |
// Isolation: unspecified | |
sil private [transparent] @$s9ViewModelAAC5_name33_1E59A94D38984979103BAB9BD1543592LLSSvs : $@convention(method) (@owned String, @guaranteed ViewModel) -> () { | |
// %0 "value" // users: %11, %8, %4, %2 | |
// %1 "self" // users: %5, %3 | |
bb0(%0 : $String, %1 : $ViewModel): | |
debug_value %0 : $String, let, name "value", argno 1 // id: %2 | |
debug_value %1 : $ViewModel, let, name "self", argno 2 // id: %3 | |
retain_value %0 : $String // id: %4 | |
%5 = ref_element_addr %1 : $ViewModel, #ViewModel._name // user: %6 | |
%6 = begin_access [modify] [dynamic] %5 : $*String // users: %8, %7, %10 | |
%7 = load %6 : $*String // user: %9 | |
store %0 to %6 : $*String // id: %8 | |
release_value %7 : $String // id: %9 | |
end_access %6 : $*String // id: %10 | |
release_value %0 : $String // id: %11 | |
%12 = tuple () // user: %13 | |
return %12 : $() // id: %13 | |
} // end sil function '$s9ViewModelAAC5_name33_1E59A94D38984979103BAB9BD1543592LLSSvs' | |
// ViewModel._name.modify | |
// Isolation: unspecified | |
sil private [transparent] @$s9ViewModelAAC5_name33_1E59A94D38984979103BAB9BD1543592LLSSvM : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout String { | |
// %0 "self" // users: %2, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = ref_element_addr %0 : $ViewModel, #ViewModel._name // user: %3 | |
%3 = begin_access [modify] [dynamic] %2 : $*String // users: %5, %8, %4 | |
yield %3 : $*String, resume bb1, unwind bb2 // id: %4 | |
bb1: // Preds: bb0 | |
end_access %3 : $*String // id: %5 | |
%6 = tuple () // user: %7 | |
return %6 : $() // id: %7 | |
bb2: // Preds: bb0 | |
end_access %3 : $*String // id: %8 | |
unwind // id: %9 | |
} // end sil function '$s9ViewModelAAC5_name33_1E59A94D38984979103BAB9BD1543592LLSSvM' | |
// ViewModel.name.init | |
// Isolation: unspecified | |
sil hidden @$s9ViewModelAAC4nameSSvi : $@convention(thin) (@owned String, @thick ViewModel.Type) -> @out String { | |
// %0 "_name" // user: %5 | |
// %1 "initialValue" // users: %8, %6, %4, %3 | |
// %2 "$metatype" | |
bb0(%0 : $*String, %1 : $String, %2 : $@thick ViewModel.Type): | |
debug_value %1 : $String, let, name "initialValue", argno 1 // id: %3 | |
retain_value %1 : $String // id: %4 | |
%5 = begin_access [modify] [static] %0 : $*String // users: %6, %7 | |
store %1 to %5 : $*String // id: %6 | |
end_access %5 : $*String // id: %7 | |
release_value %1 : $String // id: %8 | |
%9 = tuple () // user: %10 | |
return %9 : $() // id: %10 | |
} // end sil function '$s9ViewModelAAC4nameSSvi' | |
// ViewModel.name.getter | |
// Isolation: unspecified | |
sil hidden @$s9ViewModelAAC4nameSSvg : $@convention(method) (@guaranteed ViewModel) -> @owned String { | |
// %0 "self" // users: %7, %5, %4, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = keypath $ReferenceWritableKeyPath<ViewModel, String>, (root $ViewModel; settable_property $String, id #ViewModel.name!getter : (ViewModel) -> () -> String, getter @$s9ViewModelAAC4nameSSvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out String, setter @$s9ViewModelAAC4nameSSvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed String, @in_guaranteed ViewModel) -> ()) // user: %3 | |
%3 = upcast %2 : $ReferenceWritableKeyPath<ViewModel, String> to $KeyPath<ViewModel, String> // users: %6, %5 | |
%4 = class_method %0 : $ViewModel, #ViewModel.access : <Member> (ViewModel) -> (KeyPath<ViewModel, Member>) -> (), $@convention(method) <τ_0_0> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed ViewModel) -> () // user: %5 | |
%5 = apply %4<String>(%3, %0) : $@convention(method) <τ_0_0> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed ViewModel) -> () | |
strong_release %3 : $KeyPath<ViewModel, String> // id: %6 | |
%7 = ref_element_addr %0 : $ViewModel, #ViewModel._name // user: %8 | |
%8 = begin_access [read] [dynamic] %7 : $*String // users: %9, %11 | |
%9 = load %8 : $*String // users: %12, %10 | |
retain_value %9 : $String // id: %10 | |
end_access %8 : $*String // id: %11 | |
return %9 : $String // id: %12 | |
} // end sil function '$s9ViewModelAAC4nameSSvg' | |
// key path getter for ViewModel.name : ViewModel | |
sil shared [thunk] @$s9ViewModelAAC4nameSSvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out String { | |
// %0 // user: %7 | |
// %1 // user: %3 | |
bb0(%0 : $*String, %1 : $*ViewModel): | |
%2 = alloc_stack $ViewModel // users: %4, %9, %3 | |
copy_addr %1 to [init] %2 : $*ViewModel // id: %3 | |
%4 = load %2 : $*ViewModel // users: %8, %6, %5 | |
%5 = class_method %4 : $ViewModel, #ViewModel.name!getter : (ViewModel) -> () -> String, $@convention(method) (@guaranteed ViewModel) -> @owned String // user: %6 | |
%6 = apply %5(%4) : $@convention(method) (@guaranteed ViewModel) -> @owned String // user: %7 | |
store %6 to %0 : $*String // id: %7 | |
strong_release %4 : $ViewModel // id: %8 | |
dealloc_stack %2 : $*ViewModel // id: %9 | |
%10 = tuple () // user: %11 | |
return %10 : $() // id: %11 | |
} // end sil function '$s9ViewModelAAC4nameSSvpABTK' | |
// key path setter for ViewModel.name : ViewModel | |
sil shared [thunk] @$s9ViewModelAAC4nameSSvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed String, @in_guaranteed ViewModel) -> () { | |
// %0 // user: %3 | |
// %1 // user: %6 | |
bb0(%0 : $*String, %1 : $*ViewModel): | |
%2 = alloc_stack $String // users: %4, %12, %3 | |
copy_addr %0 to [init] %2 : $*String // id: %3 | |
%4 = load %2 : $*String // user: %9 | |
%5 = alloc_stack $ViewModel // users: %7, %11, %6 | |
copy_addr %1 to [init] %5 : $*ViewModel // id: %6 | |
%7 = load %5 : $*ViewModel // users: %10, %8, %9 | |
%8 = class_method %7 : $ViewModel, #ViewModel.name!setter : (ViewModel) -> (String) -> (), $@convention(method) (@owned String, @guaranteed ViewModel) -> () // user: %9 | |
%9 = apply %8(%4, %7) : $@convention(method) (@owned String, @guaranteed ViewModel) -> () | |
strong_release %7 : $ViewModel // id: %10 | |
dealloc_stack %5 : $*ViewModel // id: %11 | |
dealloc_stack %2 : $*String // id: %12 | |
%13 = tuple () // user: %14 | |
return %13 : $() // id: %14 | |
} // end sil function '$s9ViewModelAAC4nameSSvpABTk' | |
// ViewModel.name.setter | |
// Isolation: unspecified | |
sil hidden @$s9ViewModelAAC4nameSSvs : $@convention(method) (@owned String, @guaranteed ViewModel) -> () { | |
// %0 "newValue" // users: %27, %21, %18, %12, %10, %9, %2 | |
// %1 "self" // users: %26, %17, %11, %10, %8, %14, %13, %3 | |
bb0(%0 : $String, %1 : $ViewModel): | |
debug_value %0 : $String, let, name "newValue", argno 1 // id: %2 | |
debug_value %1 : $ViewModel, let, name "self", argno 2 // id: %3 | |
%4 = alloc_stack $() // users: %20, %14 | |
%5 = keypath $ReferenceWritableKeyPath<ViewModel, String>, (root $ViewModel; settable_property $String, id #ViewModel.name!getter : (ViewModel) -> () -> String, getter @$s9ViewModelAAC4nameSSvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out String, setter @$s9ViewModelAAC4nameSSvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed String, @in_guaranteed ViewModel) -> ()) // user: %6 | |
%6 = upcast %5 : $ReferenceWritableKeyPath<ViewModel, String> to $KeyPath<ViewModel, String> // users: %19, %14 | |
// function_ref closure #1 in ViewModel.name.setter | |
%7 = function_ref @$s9ViewModelAAC4nameSSvsyyXEfU_ : $@convention(thin) @substituted <τ_0_0> (@guaranteed ViewModel, @guaranteed String) -> (@out τ_0_0, @error any Error) for <()> // user: %10 | |
strong_retain %1 : $ViewModel // id: %8 | |
retain_value %0 : $String // id: %9 | |
%10 = partial_apply [callee_guaranteed] [on_stack] %7(%1, %0) : $@convention(thin) @substituted <τ_0_0> (@guaranteed ViewModel, @guaranteed String) -> (@out τ_0_0, @error any Error) for <()> // users: %11, %25, %16 | |
%11 = mark_dependence %10 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <()> on %1 : $ViewModel // user: %12 | |
%12 = mark_dependence %11 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <()> on %0 : $String // user: %14 | |
%13 = class_method %1 : $ViewModel, #ViewModel.withMutation : <Member, MutationResult> (ViewModel) -> (KeyPath<ViewModel, Member>, () throws -> MutationResult) throws -> MutationResult, $@convention(method) <τ_0_0, τ_0_1> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed @noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <τ_0_1>, @guaranteed ViewModel) -> (@out τ_0_1, @error any Error) // user: %14 | |
try_apply %13<String, ()>(%4, %6, %12, %1) : $@convention(method) <τ_0_0, τ_0_1> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed @noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <τ_0_1>, @guaranteed ViewModel) -> (@out τ_0_1, @error any Error), normal bb1, error bb2 // id: %14 | |
bb1(%15 : $()): // Preds: bb0 | |
dealloc_stack %10 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <()> // id: %16 | |
strong_release %1 : $ViewModel // id: %17 | |
release_value %0 : $String // id: %18 | |
strong_release %6 : $KeyPath<ViewModel, String> // id: %19 | |
dealloc_stack %4 : $*() // id: %20 | |
release_value %0 : $String // id: %21 | |
%22 = tuple () // user: %23 | |
return %22 : $() // id: %23 | |
bb2(%24 : $any Error): // Preds: bb0 | |
dealloc_stack %10 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <()> // id: %25 | |
strong_release %1 : $ViewModel // id: %26 | |
release_value %0 : $String // id: %27 | |
unreachable // id: %28 | |
} // end sil function '$s9ViewModelAAC4nameSSvs' | |
// closure #1 in ViewModel.name.setter | |
// Isolation: nonisolated | |
sil private @$s9ViewModelAAC4nameSSvsyyXEfU_ : $@convention(thin) @substituted <τ_0_0> (@guaranteed ViewModel, @guaranteed String) -> (@out τ_0_0, @error any Error) for <()> { | |
// %0 "$return_value" | |
// %1 "self" // users: %8, %4 | |
// %2 "newValue" // users: %14, %11, %7, %6, %5 | |
bb0(%0 : $*(), %1 : @closureCapture $ViewModel, %2 : @closureCapture $String): | |
debug_value undef : $any Error, var, name "$error", argno 1 // id: %3 | |
debug_value %1 : $ViewModel, let, name "self", argno 2 // id: %4 | |
debug_value %2 : $String, let, name "newValue", argno 3 // id: %5 | |
retain_value %2 : $String // id: %6 | |
retain_value %2 : $String // id: %7 | |
%8 = ref_element_addr %1 : $ViewModel, #ViewModel._name // user: %9 | |
%9 = begin_access [modify] [dynamic] %8 : $*String // users: %11, %10, %13 | |
%10 = load %9 : $*String // user: %12 | |
store %2 to %9 : $*String // id: %11 | |
release_value %10 : $String // id: %12 | |
end_access %9 : $*String // id: %13 | |
release_value %2 : $String // id: %14 | |
%15 = tuple () // user: %16 | |
return %15 : $() // id: %16 | |
} // end sil function '$s9ViewModelAAC4nameSSvsyyXEfU_' | |
// ViewModel.name.modify | |
// Isolation: unspecified | |
sil hidden @$s9ViewModelAAC4nameSSvM : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout String { | |
// %0 "self" // users: %11, %21, %26, %31, %7, %5, %4, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = keypath $ReferenceWritableKeyPath<ViewModel, String>, (root $ViewModel; settable_property $String, id #ViewModel.name!getter : (ViewModel) -> () -> String, getter @$s9ViewModelAAC4nameSSvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out String, setter @$s9ViewModelAAC4nameSSvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed String, @in_guaranteed ViewModel) -> ()) // user: %3 | |
%3 = upcast %2 : $ReferenceWritableKeyPath<ViewModel, String> to $KeyPath<ViewModel, String> // users: %6, %5 | |
%4 = class_method %0 : $ViewModel, #ViewModel.access : <Member> (ViewModel) -> (KeyPath<ViewModel, Member>) -> (), $@convention(method) <τ_0_0> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed ViewModel) -> () // user: %5 | |
%5 = apply %4<String>(%3, %0) : $@convention(method) <τ_0_0> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed ViewModel) -> () | |
strong_release %3 : $KeyPath<ViewModel, String> // id: %6 | |
%7 = ref_element_addr [immutable] %0 : $ViewModel, #ViewModel._$observationRegistrar // user: %9 | |
%8 = alloc_stack $ObservationRegistrar // users: %19, %18, %15, %9 | |
copy_addr %7 to [init] %8 : $*ObservationRegistrar // id: %9 | |
%10 = alloc_stack $ViewModel // users: %15, %11, %17 | |
store %0 to %10 : $*ViewModel // id: %11 | |
%12 = keypath $ReferenceWritableKeyPath<ViewModel, String>, (root $ViewModel; settable_property $String, id #ViewModel.name!getter : (ViewModel) -> () -> String, getter @$s9ViewModelAAC4nameSSvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out String, setter @$s9ViewModelAAC4nameSSvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed String, @in_guaranteed ViewModel) -> ()) // user: %13 | |
%13 = upcast %12 : $ReferenceWritableKeyPath<ViewModel, String> to $KeyPath<ViewModel, String> // users: %16, %15 | |
// function_ref ObservationRegistrar.willSet<A, B>(_:keyPath:) | |
%14 = function_ref @$s11Observation0A9RegistrarV7willSet_7keyPathyx_s03KeyF0Cyxq_GtAA10ObservableRzr0_lF : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () // user: %15 | |
%15 = apply %14<ViewModel, String>(%10, %13, %8) : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () | |
strong_release %13 : $KeyPath<ViewModel, String> // id: %16 | |
dealloc_stack %10 : $*ViewModel // id: %17 | |
destroy_addr %8 : $*ObservationRegistrar // id: %18 | |
dealloc_stack %8 : $*ObservationRegistrar // id: %19 | |
// function_ref ViewModel._name.modify | |
%20 = function_ref @$s9ViewModelAAC5_name33_1E59A94D38984979103BAB9BD1543592LLSSvM : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout String // user: %21 | |
(%21, %22) = begin_apply %20(%0) : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout String // users: %23, %29, %24 | |
yield %21 : $*String, resume bb1, unwind bb2 // id: %23 | |
bb1: // Preds: bb0 | |
%24 = end_apply %22 as $() | |
// function_ref $defer #1 () in ViewModel.name.modify | |
%25 = function_ref @$s9ViewModelAAC4nameSSvM6$deferL_yyF : $@convention(thin) (@guaranteed ViewModel) -> () // user: %26 | |
%26 = apply %25(%0) : $@convention(thin) (@guaranteed ViewModel) -> () | |
%27 = tuple () // user: %28 | |
return %27 : $() // id: %28 | |
bb2: // Preds: bb0 | |
%29 = end_apply %22 as $() | |
// function_ref $defer #1 () in ViewModel.name.modify | |
%30 = function_ref @$s9ViewModelAAC4nameSSvM6$deferL_yyF : $@convention(thin) (@guaranteed ViewModel) -> () // user: %31 | |
%31 = apply %30(%0) : $@convention(thin) (@guaranteed ViewModel) -> () | |
unwind // id: %32 | |
} // end sil function '$s9ViewModelAAC4nameSSvM' | |
// ObservationRegistrar.willSet<A, B>(_:keyPath:) | |
// Isolation: unspecified | |
sil [available 14.0] @$s11Observation0A9RegistrarV7willSet_7keyPathyx_s03KeyF0Cyxq_GtAA10ObservableRzr0_lF : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () | |
// $defer #1 () in ViewModel.name.modify | |
// Isolation: unspecified | |
sil private @$s9ViewModelAAC4nameSSvM6$deferL_yyF : $@convention(thin) (@guaranteed ViewModel) -> () { | |
// %0 "self" // users: %6, %2, %1 | |
bb0(%0 : @closureCapture $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = ref_element_addr [immutable] %0 : $ViewModel, #ViewModel._$observationRegistrar // user: %4 | |
%3 = alloc_stack $ObservationRegistrar // users: %14, %13, %10, %4 | |
copy_addr %2 to [init] %3 : $*ObservationRegistrar // id: %4 | |
%5 = alloc_stack $ViewModel // users: %10, %6, %12 | |
store %0 to %5 : $*ViewModel // id: %6 | |
%7 = keypath $ReferenceWritableKeyPath<ViewModel, String>, (root $ViewModel; settable_property $String, id #ViewModel.name!getter : (ViewModel) -> () -> String, getter @$s9ViewModelAAC4nameSSvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out String, setter @$s9ViewModelAAC4nameSSvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed String, @in_guaranteed ViewModel) -> ()) // user: %8 | |
%8 = upcast %7 : $ReferenceWritableKeyPath<ViewModel, String> to $KeyPath<ViewModel, String> // users: %11, %10 | |
// function_ref ObservationRegistrar.didSet<A, B>(_:keyPath:) | |
%9 = function_ref @$s11Observation0A9RegistrarV6didSet_7keyPathyx_s03KeyF0Cyxq_GtAA10ObservableRzr0_lF : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () // user: %10 | |
%10 = apply %9<ViewModel, String>(%5, %8, %3) : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () | |
strong_release %8 : $KeyPath<ViewModel, String> // id: %11 | |
dealloc_stack %5 : $*ViewModel // id: %12 | |
destroy_addr %3 : $*ObservationRegistrar // id: %13 | |
dealloc_stack %3 : $*ObservationRegistrar // id: %14 | |
%15 = tuple () // user: %16 | |
return %15 : $() // id: %16 | |
} // end sil function '$s9ViewModelAAC4nameSSvM6$deferL_yyF' | |
// variable initialization expression of ViewModel.title | |
// Isolation: unspecified | |
sil hidden [transparent] @$s9ViewModelAAC5titleSSvpfi : $@convention(thin) () -> @owned String { | |
bb0: | |
%0 = string_literal utf8 "Developer" // user: %5 | |
%1 = integer_literal $Builtin.Word, 9 // user: %5 | |
%2 = integer_literal $Builtin.Int1, -1 // user: %5 | |
%3 = metatype $@thin String.Type // user: %5 | |
// function_ref String.init(_builtinStringLiteral:utf8CodeUnitCount:isASCII:) | |
%4 = function_ref @$sSS21_builtinStringLiteral17utf8CodeUnitCount7isASCIISSBp_BwBi1_tcfC : $@convention(method) (Builtin.RawPointer, Builtin.Word, Builtin.Int1, @thin String.Type) -> @owned String // user: %5 | |
%5 = apply %4(%0, %1, %2, %3) : $@convention(method) (Builtin.RawPointer, Builtin.Word, Builtin.Int1, @thin String.Type) -> @owned String // user: %6 | |
return %5 : $String // id: %6 | |
} // end sil function '$s9ViewModelAAC5titleSSvpfi' | |
// ViewModel._title.getter | |
// Isolation: unspecified | |
sil private [transparent] @$s9ViewModelAAC6_title33_1E59A94D38984979103BAB9BD1543592LLSSvg : $@convention(method) (@guaranteed ViewModel) -> @owned String { | |
// %0 "self" // users: %2, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = ref_element_addr %0 : $ViewModel, #ViewModel._title // user: %3 | |
%3 = begin_access [read] [dynamic] %2 : $*String // users: %4, %6 | |
%4 = load %3 : $*String // users: %7, %5 | |
retain_value %4 : $String // id: %5 | |
end_access %3 : $*String // id: %6 | |
return %4 : $String // id: %7 | |
} // end sil function '$s9ViewModelAAC6_title33_1E59A94D38984979103BAB9BD1543592LLSSvg' | |
// ViewModel._title.setter | |
// Isolation: unspecified | |
sil private [transparent] @$s9ViewModelAAC6_title33_1E59A94D38984979103BAB9BD1543592LLSSvs : $@convention(method) (@owned String, @guaranteed ViewModel) -> () { | |
// %0 "value" // users: %11, %8, %4, %2 | |
// %1 "self" // users: %5, %3 | |
bb0(%0 : $String, %1 : $ViewModel): | |
debug_value %0 : $String, let, name "value", argno 1 // id: %2 | |
debug_value %1 : $ViewModel, let, name "self", argno 2 // id: %3 | |
retain_value %0 : $String // id: %4 | |
%5 = ref_element_addr %1 : $ViewModel, #ViewModel._title // user: %6 | |
%6 = begin_access [modify] [dynamic] %5 : $*String // users: %8, %7, %10 | |
%7 = load %6 : $*String // user: %9 | |
store %0 to %6 : $*String // id: %8 | |
release_value %7 : $String // id: %9 | |
end_access %6 : $*String // id: %10 | |
release_value %0 : $String // id: %11 | |
%12 = tuple () // user: %13 | |
return %12 : $() // id: %13 | |
} // end sil function '$s9ViewModelAAC6_title33_1E59A94D38984979103BAB9BD1543592LLSSvs' | |
// ViewModel._title.modify | |
// Isolation: unspecified | |
sil private [transparent] @$s9ViewModelAAC6_title33_1E59A94D38984979103BAB9BD1543592LLSSvM : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout String { | |
// %0 "self" // users: %2, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = ref_element_addr %0 : $ViewModel, #ViewModel._title // user: %3 | |
%3 = begin_access [modify] [dynamic] %2 : $*String // users: %5, %8, %4 | |
yield %3 : $*String, resume bb1, unwind bb2 // id: %4 | |
bb1: // Preds: bb0 | |
end_access %3 : $*String // id: %5 | |
%6 = tuple () // user: %7 | |
return %6 : $() // id: %7 | |
bb2: // Preds: bb0 | |
end_access %3 : $*String // id: %8 | |
unwind // id: %9 | |
} // end sil function '$s9ViewModelAAC6_title33_1E59A94D38984979103BAB9BD1543592LLSSvM' | |
// ViewModel.title.init | |
// Isolation: unspecified | |
sil hidden @$s9ViewModelAAC5titleSSvi : $@convention(thin) (@owned String, @thick ViewModel.Type) -> @out String { | |
// %0 "_title" // user: %5 | |
// %1 "initialValue" // users: %8, %6, %4, %3 | |
// %2 "$metatype" | |
bb0(%0 : $*String, %1 : $String, %2 : $@thick ViewModel.Type): | |
debug_value %1 : $String, let, name "initialValue", argno 1 // id: %3 | |
retain_value %1 : $String // id: %4 | |
%5 = begin_access [modify] [static] %0 : $*String // users: %6, %7 | |
store %1 to %5 : $*String // id: %6 | |
end_access %5 : $*String // id: %7 | |
release_value %1 : $String // id: %8 | |
%9 = tuple () // user: %10 | |
return %9 : $() // id: %10 | |
} // end sil function '$s9ViewModelAAC5titleSSvi' | |
// ViewModel.title.getter | |
// Isolation: unspecified | |
sil hidden @$s9ViewModelAAC5titleSSvg : $@convention(method) (@guaranteed ViewModel) -> @owned String { | |
// %0 "self" // users: %7, %5, %4, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = keypath $ReferenceWritableKeyPath<ViewModel, String>, (root $ViewModel; settable_property $String, id #ViewModel.title!getter : (ViewModel) -> () -> String, getter @$s9ViewModelAAC5titleSSvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out String, setter @$s9ViewModelAAC5titleSSvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed String, @in_guaranteed ViewModel) -> ()) // user: %3 | |
%3 = upcast %2 : $ReferenceWritableKeyPath<ViewModel, String> to $KeyPath<ViewModel, String> // users: %6, %5 | |
%4 = class_method %0 : $ViewModel, #ViewModel.access : <Member> (ViewModel) -> (KeyPath<ViewModel, Member>) -> (), $@convention(method) <τ_0_0> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed ViewModel) -> () // user: %5 | |
%5 = apply %4<String>(%3, %0) : $@convention(method) <τ_0_0> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed ViewModel) -> () | |
strong_release %3 : $KeyPath<ViewModel, String> // id: %6 | |
%7 = ref_element_addr %0 : $ViewModel, #ViewModel._title // user: %8 | |
%8 = begin_access [read] [dynamic] %7 : $*String // users: %9, %11 | |
%9 = load %8 : $*String // users: %12, %10 | |
retain_value %9 : $String // id: %10 | |
end_access %8 : $*String // id: %11 | |
return %9 : $String // id: %12 | |
} // end sil function '$s9ViewModelAAC5titleSSvg' | |
// key path getter for ViewModel.title : ViewModel | |
sil shared [thunk] @$s9ViewModelAAC5titleSSvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out String { | |
// %0 // user: %7 | |
// %1 // user: %3 | |
bb0(%0 : $*String, %1 : $*ViewModel): | |
%2 = alloc_stack $ViewModel // users: %4, %9, %3 | |
copy_addr %1 to [init] %2 : $*ViewModel // id: %3 | |
%4 = load %2 : $*ViewModel // users: %8, %6, %5 | |
%5 = class_method %4 : $ViewModel, #ViewModel.title!getter : (ViewModel) -> () -> String, $@convention(method) (@guaranteed ViewModel) -> @owned String // user: %6 | |
%6 = apply %5(%4) : $@convention(method) (@guaranteed ViewModel) -> @owned String // user: %7 | |
store %6 to %0 : $*String // id: %7 | |
strong_release %4 : $ViewModel // id: %8 | |
dealloc_stack %2 : $*ViewModel // id: %9 | |
%10 = tuple () // user: %11 | |
return %10 : $() // id: %11 | |
} // end sil function '$s9ViewModelAAC5titleSSvpABTK' | |
// key path setter for ViewModel.title : ViewModel | |
sil shared [thunk] @$s9ViewModelAAC5titleSSvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed String, @in_guaranteed ViewModel) -> () { | |
// %0 // user: %3 | |
// %1 // user: %6 | |
bb0(%0 : $*String, %1 : $*ViewModel): | |
%2 = alloc_stack $String // users: %4, %12, %3 | |
copy_addr %0 to [init] %2 : $*String // id: %3 | |
%4 = load %2 : $*String // user: %9 | |
%5 = alloc_stack $ViewModel // users: %7, %11, %6 | |
copy_addr %1 to [init] %5 : $*ViewModel // id: %6 | |
%7 = load %5 : $*ViewModel // users: %10, %8, %9 | |
%8 = class_method %7 : $ViewModel, #ViewModel.title!setter : (ViewModel) -> (String) -> (), $@convention(method) (@owned String, @guaranteed ViewModel) -> () // user: %9 | |
%9 = apply %8(%4, %7) : $@convention(method) (@owned String, @guaranteed ViewModel) -> () | |
strong_release %7 : $ViewModel // id: %10 | |
dealloc_stack %5 : $*ViewModel // id: %11 | |
dealloc_stack %2 : $*String // id: %12 | |
%13 = tuple () // user: %14 | |
return %13 : $() // id: %14 | |
} // end sil function '$s9ViewModelAAC5titleSSvpABTk' | |
// ViewModel.title.setter | |
// Isolation: unspecified | |
sil hidden @$s9ViewModelAAC5titleSSvs : $@convention(method) (@owned String, @guaranteed ViewModel) -> () { | |
// %0 "newValue" // users: %27, %21, %18, %12, %10, %9, %2 | |
// %1 "self" // users: %26, %17, %11, %10, %8, %14, %13, %3 | |
bb0(%0 : $String, %1 : $ViewModel): | |
debug_value %0 : $String, let, name "newValue", argno 1 // id: %2 | |
debug_value %1 : $ViewModel, let, name "self", argno 2 // id: %3 | |
%4 = alloc_stack $() // users: %20, %14 | |
%5 = keypath $ReferenceWritableKeyPath<ViewModel, String>, (root $ViewModel; settable_property $String, id #ViewModel.title!getter : (ViewModel) -> () -> String, getter @$s9ViewModelAAC5titleSSvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out String, setter @$s9ViewModelAAC5titleSSvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed String, @in_guaranteed ViewModel) -> ()) // user: %6 | |
%6 = upcast %5 : $ReferenceWritableKeyPath<ViewModel, String> to $KeyPath<ViewModel, String> // users: %19, %14 | |
// function_ref closure #1 in ViewModel.title.setter | |
%7 = function_ref @$s9ViewModelAAC5titleSSvsyyXEfU_ : $@convention(thin) @substituted <τ_0_0> (@guaranteed ViewModel, @guaranteed String) -> (@out τ_0_0, @error any Error) for <()> // user: %10 | |
strong_retain %1 : $ViewModel // id: %8 | |
retain_value %0 : $String // id: %9 | |
%10 = partial_apply [callee_guaranteed] [on_stack] %7(%1, %0) : $@convention(thin) @substituted <τ_0_0> (@guaranteed ViewModel, @guaranteed String) -> (@out τ_0_0, @error any Error) for <()> // users: %11, %25, %16 | |
%11 = mark_dependence %10 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <()> on %1 : $ViewModel // user: %12 | |
%12 = mark_dependence %11 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <()> on %0 : $String // user: %14 | |
%13 = class_method %1 : $ViewModel, #ViewModel.withMutation : <Member, MutationResult> (ViewModel) -> (KeyPath<ViewModel, Member>, () throws -> MutationResult) throws -> MutationResult, $@convention(method) <τ_0_0, τ_0_1> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed @noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <τ_0_1>, @guaranteed ViewModel) -> (@out τ_0_1, @error any Error) // user: %14 | |
try_apply %13<String, ()>(%4, %6, %12, %1) : $@convention(method) <τ_0_0, τ_0_1> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed @noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <τ_0_1>, @guaranteed ViewModel) -> (@out τ_0_1, @error any Error), normal bb1, error bb2 // id: %14 | |
bb1(%15 : $()): // Preds: bb0 | |
dealloc_stack %10 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <()> // id: %16 | |
strong_release %1 : $ViewModel // id: %17 | |
release_value %0 : $String // id: %18 | |
strong_release %6 : $KeyPath<ViewModel, String> // id: %19 | |
dealloc_stack %4 : $*() // id: %20 | |
release_value %0 : $String // id: %21 | |
%22 = tuple () // user: %23 | |
return %22 : $() // id: %23 | |
bb2(%24 : $any Error): // Preds: bb0 | |
dealloc_stack %10 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <()> // id: %25 | |
strong_release %1 : $ViewModel // id: %26 | |
release_value %0 : $String // id: %27 | |
unreachable // id: %28 | |
} // end sil function '$s9ViewModelAAC5titleSSvs' | |
// closure #1 in ViewModel.title.setter | |
// Isolation: nonisolated | |
sil private @$s9ViewModelAAC5titleSSvsyyXEfU_ : $@convention(thin) @substituted <τ_0_0> (@guaranteed ViewModel, @guaranteed String) -> (@out τ_0_0, @error any Error) for <()> { | |
// %0 "$return_value" | |
// %1 "self" // users: %8, %4 | |
// %2 "newValue" // users: %14, %11, %7, %6, %5 | |
bb0(%0 : $*(), %1 : @closureCapture $ViewModel, %2 : @closureCapture $String): | |
debug_value undef : $any Error, var, name "$error", argno 1 // id: %3 | |
debug_value %1 : $ViewModel, let, name "self", argno 2 // id: %4 | |
debug_value %2 : $String, let, name "newValue", argno 3 // id: %5 | |
retain_value %2 : $String // id: %6 | |
retain_value %2 : $String // id: %7 | |
%8 = ref_element_addr %1 : $ViewModel, #ViewModel._title // user: %9 | |
%9 = begin_access [modify] [dynamic] %8 : $*String // users: %11, %10, %13 | |
%10 = load %9 : $*String // user: %12 | |
store %2 to %9 : $*String // id: %11 | |
release_value %10 : $String // id: %12 | |
end_access %9 : $*String // id: %13 | |
release_value %2 : $String // id: %14 | |
%15 = tuple () // user: %16 | |
return %15 : $() // id: %16 | |
} // end sil function '$s9ViewModelAAC5titleSSvsyyXEfU_' | |
// ViewModel.title.modify | |
// Isolation: unspecified | |
sil hidden @$s9ViewModelAAC5titleSSvM : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout String { | |
// %0 "self" // users: %11, %21, %26, %31, %7, %5, %4, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = keypath $ReferenceWritableKeyPath<ViewModel, String>, (root $ViewModel; settable_property $String, id #ViewModel.title!getter : (ViewModel) -> () -> String, getter @$s9ViewModelAAC5titleSSvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out String, setter @$s9ViewModelAAC5titleSSvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed String, @in_guaranteed ViewModel) -> ()) // user: %3 | |
%3 = upcast %2 : $ReferenceWritableKeyPath<ViewModel, String> to $KeyPath<ViewModel, String> // users: %6, %5 | |
%4 = class_method %0 : $ViewModel, #ViewModel.access : <Member> (ViewModel) -> (KeyPath<ViewModel, Member>) -> (), $@convention(method) <τ_0_0> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed ViewModel) -> () // user: %5 | |
%5 = apply %4<String>(%3, %0) : $@convention(method) <τ_0_0> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed ViewModel) -> () | |
strong_release %3 : $KeyPath<ViewModel, String> // id: %6 | |
%7 = ref_element_addr [immutable] %0 : $ViewModel, #ViewModel._$observationRegistrar // user: %9 | |
%8 = alloc_stack $ObservationRegistrar // users: %19, %18, %15, %9 | |
copy_addr %7 to [init] %8 : $*ObservationRegistrar // id: %9 | |
%10 = alloc_stack $ViewModel // users: %15, %11, %17 | |
store %0 to %10 : $*ViewModel // id: %11 | |
%12 = keypath $ReferenceWritableKeyPath<ViewModel, String>, (root $ViewModel; settable_property $String, id #ViewModel.title!getter : (ViewModel) -> () -> String, getter @$s9ViewModelAAC5titleSSvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out String, setter @$s9ViewModelAAC5titleSSvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed String, @in_guaranteed ViewModel) -> ()) // user: %13 | |
%13 = upcast %12 : $ReferenceWritableKeyPath<ViewModel, String> to $KeyPath<ViewModel, String> // users: %16, %15 | |
// function_ref ObservationRegistrar.willSet<A, B>(_:keyPath:) | |
%14 = function_ref @$s11Observation0A9RegistrarV7willSet_7keyPathyx_s03KeyF0Cyxq_GtAA10ObservableRzr0_lF : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () // user: %15 | |
%15 = apply %14<ViewModel, String>(%10, %13, %8) : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () | |
strong_release %13 : $KeyPath<ViewModel, String> // id: %16 | |
dealloc_stack %10 : $*ViewModel // id: %17 | |
destroy_addr %8 : $*ObservationRegistrar // id: %18 | |
dealloc_stack %8 : $*ObservationRegistrar // id: %19 | |
// function_ref ViewModel._title.modify | |
%20 = function_ref @$s9ViewModelAAC6_title33_1E59A94D38984979103BAB9BD1543592LLSSvM : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout String // user: %21 | |
(%21, %22) = begin_apply %20(%0) : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout String // users: %23, %29, %24 | |
yield %21 : $*String, resume bb1, unwind bb2 // id: %23 | |
bb1: // Preds: bb0 | |
%24 = end_apply %22 as $() | |
// function_ref $defer #1 () in ViewModel.title.modify | |
%25 = function_ref @$s9ViewModelAAC5titleSSvM6$deferL_yyF : $@convention(thin) (@guaranteed ViewModel) -> () // user: %26 | |
%26 = apply %25(%0) : $@convention(thin) (@guaranteed ViewModel) -> () | |
%27 = tuple () // user: %28 | |
return %27 : $() // id: %28 | |
bb2: // Preds: bb0 | |
%29 = end_apply %22 as $() | |
// function_ref $defer #1 () in ViewModel.title.modify | |
%30 = function_ref @$s9ViewModelAAC5titleSSvM6$deferL_yyF : $@convention(thin) (@guaranteed ViewModel) -> () // user: %31 | |
%31 = apply %30(%0) : $@convention(thin) (@guaranteed ViewModel) -> () | |
unwind // id: %32 | |
} // end sil function '$s9ViewModelAAC5titleSSvM' | |
// $defer #1 () in ViewModel.title.modify | |
// Isolation: unspecified | |
sil private @$s9ViewModelAAC5titleSSvM6$deferL_yyF : $@convention(thin) (@guaranteed ViewModel) -> () { | |
// %0 "self" // users: %6, %2, %1 | |
bb0(%0 : @closureCapture $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = ref_element_addr [immutable] %0 : $ViewModel, #ViewModel._$observationRegistrar // user: %4 | |
%3 = alloc_stack $ObservationRegistrar // users: %14, %13, %10, %4 | |
copy_addr %2 to [init] %3 : $*ObservationRegistrar // id: %4 | |
%5 = alloc_stack $ViewModel // users: %10, %6, %12 | |
store %0 to %5 : $*ViewModel // id: %6 | |
%7 = keypath $ReferenceWritableKeyPath<ViewModel, String>, (root $ViewModel; settable_property $String, id #ViewModel.title!getter : (ViewModel) -> () -> String, getter @$s9ViewModelAAC5titleSSvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out String, setter @$s9ViewModelAAC5titleSSvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed String, @in_guaranteed ViewModel) -> ()) // user: %8 | |
%8 = upcast %7 : $ReferenceWritableKeyPath<ViewModel, String> to $KeyPath<ViewModel, String> // users: %11, %10 | |
// function_ref ObservationRegistrar.didSet<A, B>(_:keyPath:) | |
%9 = function_ref @$s11Observation0A9RegistrarV6didSet_7keyPathyx_s03KeyF0Cyxq_GtAA10ObservableRzr0_lF : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () // user: %10 | |
%10 = apply %9<ViewModel, String>(%5, %8, %3) : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () | |
strong_release %8 : $KeyPath<ViewModel, String> // id: %11 | |
dealloc_stack %5 : $*ViewModel // id: %12 | |
destroy_addr %3 : $*ObservationRegistrar // id: %13 | |
dealloc_stack %3 : $*ObservationRegistrar // id: %14 | |
%15 = tuple () // user: %16 | |
return %15 : $() // id: %16 | |
} // end sil function '$s9ViewModelAAC5titleSSvM6$deferL_yyF' | |
// variable initialization expression of ViewModel.ignored | |
// Isolation: unspecified | |
sil hidden [transparent] @$s9ViewModelAAC7ignoredSbvpfi : $@convention(thin) () -> Bool { | |
bb0: | |
%0 = integer_literal $Builtin.Int1, -1 // user: %1 | |
%1 = struct $Bool (%0 : $Builtin.Int1) // user: %2 | |
return %1 : $Bool // id: %2 | |
} // end sil function '$s9ViewModelAAC7ignoredSbvpfi' | |
// Bool.init(_builtinBooleanLiteral:) | |
// Isolation: unspecified | |
sil public_external [transparent] [_semantics "bool.literal_init"] @$sSb22_builtinBooleanLiteralSbBi1__tcfC : $@convention(method) (Builtin.Int1, @thin Bool.Type) -> Bool { | |
// %0 // user: %2 | |
bb0(%0 : $Builtin.Int1, %1 : $@thin Bool.Type): | |
%2 = struct $Bool (%0 : $Builtin.Int1) // user: %3 | |
return %2 : $Bool // id: %3 | |
} // end sil function '$sSb22_builtinBooleanLiteralSbBi1__tcfC' | |
// ViewModel.ignored.getter | |
// Isolation: unspecified | |
sil hidden [transparent] @$s9ViewModelAAC7ignoredSbvg : $@convention(method) (@guaranteed ViewModel) -> Bool { | |
// %0 "self" // users: %2, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = ref_element_addr %0 : $ViewModel, #ViewModel.ignored // user: %3 | |
%3 = begin_access [read] [dynamic] %2 : $*Bool // users: %4, %5 | |
%4 = load %3 : $*Bool // user: %6 | |
end_access %3 : $*Bool // id: %5 | |
return %4 : $Bool // id: %6 | |
} // end sil function '$s9ViewModelAAC7ignoredSbvg' | |
// ViewModel.ignored.setter | |
// Isolation: unspecified | |
sil hidden [transparent] @$s9ViewModelAAC7ignoredSbvs : $@convention(method) (Bool, @guaranteed ViewModel) -> () { | |
// %0 "value" // users: %6, %2 | |
// %1 "self" // users: %4, %3 | |
bb0(%0 : $Bool, %1 : $ViewModel): | |
debug_value %0 : $Bool, let, name "value", argno 1 // id: %2 | |
debug_value %1 : $ViewModel, let, name "self", argno 2 // id: %3 | |
%4 = ref_element_addr %1 : $ViewModel, #ViewModel.ignored // user: %5 | |
%5 = begin_access [modify] [dynamic] %4 : $*Bool // users: %6, %7 | |
store %0 to %5 : $*Bool // id: %6 | |
end_access %5 : $*Bool // id: %7 | |
%8 = tuple () // user: %9 | |
return %8 : $() // id: %9 | |
} // end sil function '$s9ViewModelAAC7ignoredSbvs' | |
// ViewModel.ignored.modify | |
// Isolation: unspecified | |
sil hidden [transparent] @$s9ViewModelAAC7ignoredSbvM : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout Bool { | |
// %0 "self" // users: %2, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = ref_element_addr %0 : $ViewModel, #ViewModel.ignored // user: %3 | |
%3 = begin_access [modify] [dynamic] %2 : $*Bool // users: %5, %8, %4 | |
yield %3 : $*Bool, resume bb1, unwind bb2 // id: %4 | |
bb1: // Preds: bb0 | |
end_access %3 : $*Bool // id: %5 | |
%6 = tuple () // user: %7 | |
return %6 : $() // id: %7 | |
bb2: // Preds: bb0 | |
end_access %3 : $*Bool // id: %8 | |
unwind // id: %9 | |
} // end sil function '$s9ViewModelAAC7ignoredSbvM' | |
// variable initialization expression of ViewModel.hasBoilerplate | |
// Isolation: unspecified | |
sil hidden [transparent] @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpfi : $@convention(thin) () -> Bool { | |
bb0: | |
%0 = integer_literal $Builtin.Int1, -1 // user: %1 | |
%1 = struct $Bool (%0 : $Builtin.Int1) // user: %2 | |
return %1 : $Bool // id: %2 | |
} // end sil function '$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpfi' | |
// ViewModel._hasBoilerplate.getter | |
// Isolation: unspecified | |
sil private [transparent] @$s9ViewModelAAC15_hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvg : $@convention(method) (@guaranteed ViewModel) -> Bool { | |
// %0 "self" // users: %2, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = ref_element_addr %0 : $ViewModel, #ViewModel._hasBoilerplate // user: %3 | |
%3 = begin_access [read] [dynamic] %2 : $*Bool // users: %4, %5 | |
%4 = load %3 : $*Bool // user: %6 | |
end_access %3 : $*Bool // id: %5 | |
return %4 : $Bool // id: %6 | |
} // end sil function '$s9ViewModelAAC15_hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvg' | |
// ViewModel._hasBoilerplate.setter | |
// Isolation: unspecified | |
sil private [transparent] @$s9ViewModelAAC15_hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvs : $@convention(method) (Bool, @guaranteed ViewModel) -> () { | |
// %0 "value" // users: %6, %2 | |
// %1 "self" // users: %4, %3 | |
bb0(%0 : $Bool, %1 : $ViewModel): | |
debug_value %0 : $Bool, let, name "value", argno 1 // id: %2 | |
debug_value %1 : $ViewModel, let, name "self", argno 2 // id: %3 | |
%4 = ref_element_addr %1 : $ViewModel, #ViewModel._hasBoilerplate // user: %5 | |
%5 = begin_access [modify] [dynamic] %4 : $*Bool // users: %6, %7 | |
store %0 to %5 : $*Bool // id: %6 | |
end_access %5 : $*Bool // id: %7 | |
%8 = tuple () // user: %9 | |
return %8 : $() // id: %9 | |
} // end sil function '$s9ViewModelAAC15_hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvs' | |
// ViewModel._hasBoilerplate.modify | |
// Isolation: unspecified | |
sil private [transparent] @$s9ViewModelAAC15_hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvM : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout Bool { | |
// %0 "self" // users: %2, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = ref_element_addr %0 : $ViewModel, #ViewModel._hasBoilerplate // user: %3 | |
%3 = begin_access [modify] [dynamic] %2 : $*Bool // users: %5, %8, %4 | |
yield %3 : $*Bool, resume bb1, unwind bb2 // id: %4 | |
bb1: // Preds: bb0 | |
end_access %3 : $*Bool // id: %5 | |
%6 = tuple () // user: %7 | |
return %6 : $() // id: %7 | |
bb2: // Preds: bb0 | |
end_access %3 : $*Bool // id: %8 | |
unwind // id: %9 | |
} // end sil function '$s9ViewModelAAC15_hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvM' | |
// ViewModel.hasBoilerplate.init | |
// Isolation: unspecified | |
sil hidden @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvi : $@convention(thin) (Bool, @thick ViewModel.Type) -> @out Bool { | |
// %0 "_hasBoilerplate" // user: %4 | |
// %1 "initialValue" // users: %5, %3 | |
// %2 "$metatype" | |
bb0(%0 : $*Bool, %1 : $Bool, %2 : $@thick ViewModel.Type): | |
debug_value %1 : $Bool, let, name "initialValue", argno 1 // id: %3 | |
%4 = begin_access [modify] [static] %0 : $*Bool // users: %5, %6 | |
store %1 to %4 : $*Bool // id: %5 | |
end_access %4 : $*Bool // id: %6 | |
%7 = tuple () // user: %8 | |
return %7 : $() // id: %8 | |
} // end sil function '$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvi' | |
// ViewModel.hasBoilerplate.getter | |
// Isolation: unspecified | |
sil private @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvg : $@convention(method) (@guaranteed ViewModel) -> Bool { | |
// %0 "self" // users: %7, %5, %4, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = keypath $ReferenceWritableKeyPath<ViewModel, Bool>, (root $ViewModel; settable_property $Bool, id #ViewModel.hasBoilerplate!getter : (ViewModel) -> () -> Bool, getter @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out Bool, setter @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed Bool, @in_guaranteed ViewModel) -> ()) // user: %3 | |
%3 = upcast %2 : $ReferenceWritableKeyPath<ViewModel, Bool> to $KeyPath<ViewModel, Bool> // users: %6, %5 | |
%4 = class_method %0 : $ViewModel, #ViewModel.access : <Member> (ViewModel) -> (KeyPath<ViewModel, Member>) -> (), $@convention(method) <τ_0_0> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed ViewModel) -> () // user: %5 | |
%5 = apply %4<Bool>(%3, %0) : $@convention(method) <τ_0_0> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed ViewModel) -> () | |
strong_release %3 : $KeyPath<ViewModel, Bool> // id: %6 | |
%7 = ref_element_addr %0 : $ViewModel, #ViewModel._hasBoilerplate // user: %8 | |
%8 = begin_access [read] [dynamic] %7 : $*Bool // users: %9, %10 | |
%9 = load %8 : $*Bool // user: %11 | |
end_access %8 : $*Bool // id: %10 | |
return %9 : $Bool // id: %11 | |
} // end sil function '$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvg' | |
// key path getter for ViewModel.hasBoilerplate : ViewModel | |
sil shared [thunk] @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out Bool { | |
// %0 // user: %7 | |
// %1 // user: %3 | |
bb0(%0 : $*Bool, %1 : $*ViewModel): | |
%2 = alloc_stack $ViewModel // users: %4, %9, %3 | |
copy_addr %1 to [init] %2 : $*ViewModel // id: %3 | |
%4 = load %2 : $*ViewModel // users: %8, %6 | |
// function_ref ViewModel.hasBoilerplate.getter | |
%5 = function_ref @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvg : $@convention(method) (@guaranteed ViewModel) -> Bool // user: %6 | |
%6 = apply %5(%4) : $@convention(method) (@guaranteed ViewModel) -> Bool // user: %7 | |
store %6 to %0 : $*Bool // id: %7 | |
strong_release %4 : $ViewModel // id: %8 | |
dealloc_stack %2 : $*ViewModel // id: %9 | |
%10 = tuple () // user: %11 | |
return %10 : $() // id: %11 | |
} // end sil function '$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTK' | |
// key path setter for ViewModel.hasBoilerplate : ViewModel | |
sil shared [thunk] @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed Bool, @in_guaranteed ViewModel) -> () { | |
// %0 // user: %2 | |
// %1 // user: %4 | |
bb0(%0 : $*Bool, %1 : $*ViewModel): | |
%2 = load %0 : $*Bool // user: %7 | |
%3 = alloc_stack $ViewModel // users: %5, %9, %4 | |
copy_addr %1 to [init] %3 : $*ViewModel // id: %4 | |
%5 = load %3 : $*ViewModel // users: %8, %7 | |
// function_ref ViewModel.hasBoilerplate.setter | |
%6 = function_ref @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvs : $@convention(method) (Bool, @guaranteed ViewModel) -> () // user: %7 | |
%7 = apply %6(%2, %5) : $@convention(method) (Bool, @guaranteed ViewModel) -> () | |
strong_release %5 : $ViewModel // id: %8 | |
dealloc_stack %3 : $*ViewModel // id: %9 | |
%10 = tuple () // user: %11 | |
return %10 : $() // id: %11 | |
} // end sil function '$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTk' | |
// ViewModel.hasBoilerplate.setter | |
// Isolation: unspecified | |
sil private @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvs : $@convention(method) (Bool, @guaranteed ViewModel) -> () { | |
// %0 "newValue" // users: %9, %2 | |
// %1 "self" // users: %22, %15, %10, %9, %8, %12, %11, %3 | |
bb0(%0 : $Bool, %1 : $ViewModel): | |
debug_value %0 : $Bool, let, name "newValue", argno 1 // id: %2 | |
debug_value %1 : $ViewModel, let, name "self", argno 2 // id: %3 | |
%4 = alloc_stack $() // users: %17, %12 | |
%5 = keypath $ReferenceWritableKeyPath<ViewModel, Bool>, (root $ViewModel; settable_property $Bool, id #ViewModel.hasBoilerplate!getter : (ViewModel) -> () -> Bool, getter @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out Bool, setter @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed Bool, @in_guaranteed ViewModel) -> ()) // user: %6 | |
%6 = upcast %5 : $ReferenceWritableKeyPath<ViewModel, Bool> to $KeyPath<ViewModel, Bool> // users: %16, %12 | |
// function_ref closure #1 in ViewModel.hasBoilerplate.setter | |
%7 = function_ref @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvsyyXEfU_ : $@convention(thin) @substituted <τ_0_0> (@guaranteed ViewModel, Bool) -> (@out τ_0_0, @error any Error) for <()> // user: %9 | |
strong_retain %1 : $ViewModel // id: %8 | |
%9 = partial_apply [callee_guaranteed] [on_stack] %7(%1, %0) : $@convention(thin) @substituted <τ_0_0> (@guaranteed ViewModel, Bool) -> (@out τ_0_0, @error any Error) for <()> // users: %10, %21, %14 | |
%10 = mark_dependence %9 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <()> on %1 : $ViewModel // user: %12 | |
%11 = class_method %1 : $ViewModel, #ViewModel.withMutation : <Member, MutationResult> (ViewModel) -> (KeyPath<ViewModel, Member>, () throws -> MutationResult) throws -> MutationResult, $@convention(method) <τ_0_0, τ_0_1> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed @noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <τ_0_1>, @guaranteed ViewModel) -> (@out τ_0_1, @error any Error) // user: %12 | |
try_apply %11<Bool, ()>(%4, %6, %10, %1) : $@convention(method) <τ_0_0, τ_0_1> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed @noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <τ_0_1>, @guaranteed ViewModel) -> (@out τ_0_1, @error any Error), normal bb1, error bb2 // id: %12 | |
bb1(%13 : $()): // Preds: bb0 | |
dealloc_stack %9 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <()> // id: %14 | |
strong_release %1 : $ViewModel // id: %15 | |
strong_release %6 : $KeyPath<ViewModel, Bool> // id: %16 | |
dealloc_stack %4 : $*() // id: %17 | |
%18 = tuple () // user: %19 | |
return %18 : $() // id: %19 | |
bb2(%20 : $any Error): // Preds: bb0 | |
dealloc_stack %9 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <()> // id: %21 | |
strong_release %1 : $ViewModel // id: %22 | |
unreachable // id: %23 | |
} // end sil function '$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvs' | |
// closure #1 in ViewModel.hasBoilerplate.setter | |
// Isolation: nonisolated | |
sil private @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvsyyXEfU_ : $@convention(thin) @substituted <τ_0_0> (@guaranteed ViewModel, Bool) -> (@out τ_0_0, @error any Error) for <()> { | |
// %0 "$return_value" | |
// %1 "self" // users: %6, %4 | |
// %2 "newValue" // users: %8, %5 | |
bb0(%0 : $*(), %1 : @closureCapture $ViewModel, %2 : @closureCapture $Bool): | |
debug_value undef : $any Error, var, name "$error", argno 1 // id: %3 | |
debug_value %1 : $ViewModel, let, name "self", argno 2 // id: %4 | |
debug_value %2 : $Bool, let, name "newValue", argno 3 // id: %5 | |
%6 = ref_element_addr %1 : $ViewModel, #ViewModel._hasBoilerplate // user: %7 | |
%7 = begin_access [modify] [dynamic] %6 : $*Bool // users: %8, %9 | |
store %2 to %7 : $*Bool // id: %8 | |
end_access %7 : $*Bool // id: %9 | |
%10 = tuple () // user: %11 | |
return %10 : $() // id: %11 | |
} // end sil function '$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvsyyXEfU_' | |
// ViewModel.hasBoilerplate.modify | |
// Isolation: unspecified | |
sil private @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvM : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout Bool { | |
// %0 "self" // users: %11, %21, %26, %31, %7, %5, %4, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = keypath $ReferenceWritableKeyPath<ViewModel, Bool>, (root $ViewModel; settable_property $Bool, id #ViewModel.hasBoilerplate!getter : (ViewModel) -> () -> Bool, getter @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out Bool, setter @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed Bool, @in_guaranteed ViewModel) -> ()) // user: %3 | |
%3 = upcast %2 : $ReferenceWritableKeyPath<ViewModel, Bool> to $KeyPath<ViewModel, Bool> // users: %6, %5 | |
%4 = class_method %0 : $ViewModel, #ViewModel.access : <Member> (ViewModel) -> (KeyPath<ViewModel, Member>) -> (), $@convention(method) <τ_0_0> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed ViewModel) -> () // user: %5 | |
%5 = apply %4<Bool>(%3, %0) : $@convention(method) <τ_0_0> (@guaranteed KeyPath<ViewModel, τ_0_0>, @guaranteed ViewModel) -> () | |
strong_release %3 : $KeyPath<ViewModel, Bool> // id: %6 | |
%7 = ref_element_addr [immutable] %0 : $ViewModel, #ViewModel._$observationRegistrar // user: %9 | |
%8 = alloc_stack $ObservationRegistrar // users: %19, %18, %15, %9 | |
copy_addr %7 to [init] %8 : $*ObservationRegistrar // id: %9 | |
%10 = alloc_stack $ViewModel // users: %15, %11, %17 | |
store %0 to %10 : $*ViewModel // id: %11 | |
%12 = keypath $ReferenceWritableKeyPath<ViewModel, Bool>, (root $ViewModel; settable_property $Bool, id #ViewModel.hasBoilerplate!getter : (ViewModel) -> () -> Bool, getter @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out Bool, setter @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed Bool, @in_guaranteed ViewModel) -> ()) // user: %13 | |
%13 = upcast %12 : $ReferenceWritableKeyPath<ViewModel, Bool> to $KeyPath<ViewModel, Bool> // users: %16, %15 | |
// function_ref ObservationRegistrar.willSet<A, B>(_:keyPath:) | |
%14 = function_ref @$s11Observation0A9RegistrarV7willSet_7keyPathyx_s03KeyF0Cyxq_GtAA10ObservableRzr0_lF : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () // user: %15 | |
%15 = apply %14<ViewModel, Bool>(%10, %13, %8) : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () | |
strong_release %13 : $KeyPath<ViewModel, Bool> // id: %16 | |
dealloc_stack %10 : $*ViewModel // id: %17 | |
destroy_addr %8 : $*ObservationRegistrar // id: %18 | |
dealloc_stack %8 : $*ObservationRegistrar // id: %19 | |
// function_ref ViewModel._hasBoilerplate.modify | |
%20 = function_ref @$s9ViewModelAAC15_hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvM : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout Bool // user: %21 | |
(%21, %22) = begin_apply %20(%0) : $@yield_once @convention(method) (@guaranteed ViewModel) -> @yields @inout Bool // users: %23, %29, %24 | |
yield %21 : $*Bool, resume bb1, unwind bb2 // id: %23 | |
bb1: // Preds: bb0 | |
%24 = end_apply %22 as $() | |
// function_ref $defer #1 () in ViewModel.hasBoilerplate.modify | |
%25 = function_ref @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvM6$deferL_yyF : $@convention(thin) (@guaranteed ViewModel) -> () // user: %26 | |
%26 = apply %25(%0) : $@convention(thin) (@guaranteed ViewModel) -> () | |
%27 = tuple () // user: %28 | |
return %27 : $() // id: %28 | |
bb2: // Preds: bb0 | |
%29 = end_apply %22 as $() | |
// function_ref $defer #1 () in ViewModel.hasBoilerplate.modify | |
%30 = function_ref @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvM6$deferL_yyF : $@convention(thin) (@guaranteed ViewModel) -> () // user: %31 | |
%31 = apply %30(%0) : $@convention(thin) (@guaranteed ViewModel) -> () | |
unwind // id: %32 | |
} // end sil function '$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvM' | |
// $defer #1 () in ViewModel.hasBoilerplate.modify | |
// Isolation: unspecified | |
sil private @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvM6$deferL_yyF : $@convention(thin) (@guaranteed ViewModel) -> () { | |
// %0 "self" // users: %6, %2, %1 | |
bb0(%0 : @closureCapture $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = ref_element_addr [immutable] %0 : $ViewModel, #ViewModel._$observationRegistrar // user: %4 | |
%3 = alloc_stack $ObservationRegistrar // users: %14, %13, %10, %4 | |
copy_addr %2 to [init] %3 : $*ObservationRegistrar // id: %4 | |
%5 = alloc_stack $ViewModel // users: %10, %6, %12 | |
store %0 to %5 : $*ViewModel // id: %6 | |
%7 = keypath $ReferenceWritableKeyPath<ViewModel, Bool>, (root $ViewModel; settable_property $Bool, id #ViewModel.hasBoilerplate!getter : (ViewModel) -> () -> Bool, getter @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTK : $@convention(keypath_accessor_getter) (@in_guaranteed ViewModel) -> @out Bool, setter @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvpABTk : $@convention(keypath_accessor_setter) (@in_guaranteed Bool, @in_guaranteed ViewModel) -> ()) // user: %8 | |
%8 = upcast %7 : $ReferenceWritableKeyPath<ViewModel, Bool> to $KeyPath<ViewModel, Bool> // users: %11, %10 | |
// function_ref ObservationRegistrar.didSet<A, B>(_:keyPath:) | |
%9 = function_ref @$s11Observation0A9RegistrarV6didSet_7keyPathyx_s03KeyF0Cyxq_GtAA10ObservableRzr0_lF : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () // user: %10 | |
%10 = apply %9<ViewModel, Bool>(%5, %8, %3) : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () | |
strong_release %8 : $KeyPath<ViewModel, Bool> // id: %11 | |
dealloc_stack %5 : $*ViewModel // id: %12 | |
destroy_addr %3 : $*ObservationRegistrar // id: %13 | |
dealloc_stack %3 : $*ObservationRegistrar // id: %14 | |
%15 = tuple () // user: %16 | |
return %15 : $() // id: %16 | |
} // end sil function '$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvM6$deferL_yyF' | |
// variable initialization expression of ViewModel._$observationRegistrar | |
// Isolation: unspecified | |
sil hidden [transparent] @$s9ViewModelAAC22_$observationRegistrar33_1E59A94D38984979103BAB9BD1543592LL11Observation0jD0Vvpfi : $@convention(thin) () -> @out ObservationRegistrar { | |
// %0 "$return_value" // user: %3 | |
bb0(%0 : $*ObservationRegistrar): | |
%1 = metatype $@thin ObservationRegistrar.Type // user: %3 | |
// function_ref ObservationRegistrar.init() | |
%2 = function_ref @$s11Observation0A9RegistrarVACycfC : $@convention(method) (@thin ObservationRegistrar.Type) -> @out ObservationRegistrar // user: %3 | |
%3 = apply %2(%0, %1) : $@convention(method) (@thin ObservationRegistrar.Type) -> @out ObservationRegistrar | |
%4 = tuple () // user: %5 | |
return %4 : $() // id: %5 | |
} // end sil function '$s9ViewModelAAC22_$observationRegistrar33_1E59A94D38984979103BAB9BD1543592LL11Observation0jD0Vvpfi' | |
// ObservationRegistrar.init() | |
// Isolation: unspecified | |
sil [available 14.0] @$s11Observation0A9RegistrarVACycfC : $@convention(method) (@thin ObservationRegistrar.Type) -> @out ObservationRegistrar | |
// ViewModel._$observationRegistrar.getter | |
// Isolation: unspecified | |
sil private [transparent] @$s9ViewModelAAC22_$observationRegistrar33_1E59A94D38984979103BAB9BD1543592LL11Observation0jD0Vvg : $@convention(method) (@guaranteed ViewModel) -> @out ObservationRegistrar { | |
// %0 "$return_value" // user: %4 | |
// %1 "self" // users: %3, %2 | |
bb0(%0 : $*ObservationRegistrar, %1 : $ViewModel): | |
debug_value %1 : $ViewModel, let, name "self", argno 1 // id: %2 | |
%3 = ref_element_addr [immutable] %1 : $ViewModel, #ViewModel._$observationRegistrar // user: %4 | |
copy_addr %3 to [init] %0 : $*ObservationRegistrar // id: %4 | |
%5 = tuple () // user: %6 | |
return %5 : $() // id: %6 | |
} // end sil function '$s9ViewModelAAC22_$observationRegistrar33_1E59A94D38984979103BAB9BD1543592LL11Observation0jD0Vvg' | |
// ViewModel.access<A>(keyPath:) | |
// Isolation: nonisolated | |
sil hidden @$s9ViewModelAAC6access7keyPathys03KeyE0CyABxG_tlF : $@convention(method) <Member> (@guaranteed KeyPath<ViewModel, Member>, @guaranteed ViewModel) -> () { | |
// %0 "keyPath" // users: %10, %2 | |
// %1 "self" // users: %8, %4, %3 | |
bb0(%0 : $KeyPath<ViewModel, Member>, %1 : $ViewModel): | |
debug_value %0 : $KeyPath<ViewModel, Member>, let, name "keyPath", argno 1 // id: %2 | |
debug_value %1 : $ViewModel, let, name "self", argno 2 // id: %3 | |
%4 = ref_element_addr [immutable] %1 : $ViewModel, #ViewModel._$observationRegistrar // user: %6 | |
%5 = alloc_stack $ObservationRegistrar // users: %13, %12, %10, %6 | |
copy_addr %4 to [init] %5 : $*ObservationRegistrar // id: %6 | |
%7 = alloc_stack $ViewModel // users: %10, %8, %11 | |
store %1 to %7 : $*ViewModel // id: %8 | |
// function_ref ObservationRegistrar.access<A, B>(_:keyPath:) | |
%9 = function_ref @$s11Observation0A9RegistrarV6access_7keyPathyx_s03KeyE0Cyxq_GtAA10ObservableRzr0_lF : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () // user: %10 | |
%10 = apply %9<ViewModel, Member>(%7, %0, %5) : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () | |
dealloc_stack %7 : $*ViewModel // id: %11 | |
destroy_addr %5 : $*ObservationRegistrar // id: %12 | |
dealloc_stack %5 : $*ObservationRegistrar // id: %13 | |
%14 = tuple () // user: %15 | |
return %14 : $() // id: %15 | |
} // end sil function '$s9ViewModelAAC6access7keyPathys03KeyE0CyABxG_tlF' | |
// ObservationRegistrar.access<A, B>(_:keyPath:) | |
// Isolation: unspecified | |
sil [available 14.0] @$s11Observation0A9RegistrarV6access_7keyPathyx_s03KeyE0Cyxq_GtAA10ObservableRzr0_lF : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () | |
// ViewModel.withMutation<A, B>(keyPath:_:) | |
// Isolation: nonisolated | |
sil hidden @$s9ViewModelAAC12withMutation7keyPath_q_s03KeyF0CyABxG_q_yKXEtKr0_lF : $@convention(method) <Member, MutationResult> (@guaranteed KeyPath<ViewModel, Member>, @guaranteed @noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <MutationResult>, @guaranteed ViewModel) -> (@out MutationResult, @error any Error) { | |
// %0 "$return_value" // user: %14 | |
// %1 "keyPath" // users: %14, %4 | |
// %2 "mutation" // users: %14, %5 | |
// %3 "self" // users: %12, %8, %6 | |
bb0(%0 : $*MutationResult, %1 : $KeyPath<ViewModel, Member>, %2 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <MutationResult>, %3 : $ViewModel): | |
debug_value %1 : $KeyPath<ViewModel, Member>, let, name "keyPath", argno 1 // id: %4 | |
debug_value %2 : $@noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <MutationResult>, let, name "mutation", argno 2 // id: %5 | |
debug_value %3 : $ViewModel, let, name "self", argno 3 // id: %6 | |
debug_value undef : $any Error, var, name "$error", argno 4 // id: %7 | |
%8 = ref_element_addr [immutable] %3 : $ViewModel, #ViewModel._$observationRegistrar // user: %10 | |
%9 = alloc_stack $ObservationRegistrar // users: %18, %17, %14, %24, %23, %10 | |
copy_addr %8 to [init] %9 : $*ObservationRegistrar // id: %10 | |
%11 = alloc_stack $ViewModel // users: %14, %12, %16, %22 | |
store %3 to %11 : $*ViewModel // id: %12 | |
// function_ref ObservationRegistrar.withMutation<A, B, C>(of:keyPath:_:) | |
%13 = function_ref @$s11Observation0A9RegistrarV12withMutation2of7keyPath_q0_x_s03KeyG0Cyxq_Gq0_yKXEtKAA10ObservableRzr1_lF : $@convention(method) <τ_0_0, τ_0_1, τ_0_2 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @guaranteed @noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <τ_0_2>, @in_guaranteed ObservationRegistrar) -> (@out τ_0_2, @error any Error) // user: %14 | |
try_apply %13<ViewModel, Member, MutationResult>(%0, %11, %1, %2, %9) : $@convention(method) <τ_0_0, τ_0_1, τ_0_2 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @guaranteed @noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <τ_0_2>, @in_guaranteed ObservationRegistrar) -> (@out τ_0_2, @error any Error), normal bb1, error bb2 // id: %14 | |
bb1(%15 : $()): // Preds: bb0 | |
dealloc_stack %11 : $*ViewModel // id: %16 | |
destroy_addr %9 : $*ObservationRegistrar // id: %17 | |
dealloc_stack %9 : $*ObservationRegistrar // id: %18 | |
%19 = tuple () // user: %20 | |
return %19 : $() // id: %20 | |
// %21 // user: %25 | |
bb2(%21 : $any Error): // Preds: bb0 | |
dealloc_stack %11 : $*ViewModel // id: %22 | |
destroy_addr %9 : $*ObservationRegistrar // id: %23 | |
dealloc_stack %9 : $*ObservationRegistrar // id: %24 | |
throw %21 : $any Error // id: %25 | |
} // end sil function '$s9ViewModelAAC12withMutation7keyPath_q_s03KeyF0CyABxG_q_yKXEtKr0_lF' | |
// ObservationRegistrar.withMutation<A, B, C>(of:keyPath:_:) | |
// Isolation: unspecified | |
sil [available 14.0] @$s11Observation0A9RegistrarV12withMutation2of7keyPath_q0_x_s03KeyG0Cyxq_Gq0_yKXEtKAA10ObservableRzr1_lF : $@convention(method) <τ_0_0, τ_0_1, τ_0_2 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @guaranteed @noescape @callee_guaranteed @substituted <τ_0_0> () -> (@out τ_0_0, @error any Error) for <τ_0_2>, @in_guaranteed ObservationRegistrar) -> (@out τ_0_2, @error any Error) | |
// ViewModel.deinit | |
// Isolation: unspecified | |
sil hidden @$s9ViewModelAACfd : $@convention(method) (@guaranteed ViewModel) -> @owned Builtin.NativeObject { | |
// %0 "self" // users: %14, %10, %6, %2, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = ref_element_addr %0 : $ViewModel, #ViewModel._name // user: %3 | |
%3 = begin_access [deinit] [static] %2 : $*String // users: %5, %4 | |
destroy_addr %3 : $*String // id: %4 | |
end_access %3 : $*String // id: %5 | |
%6 = ref_element_addr %0 : $ViewModel, #ViewModel._title // user: %7 | |
%7 = begin_access [deinit] [static] %6 : $*String // users: %9, %8 | |
destroy_addr %7 : $*String // id: %8 | |
end_access %7 : $*String // id: %9 | |
%10 = ref_element_addr %0 : $ViewModel, #ViewModel._$observationRegistrar // user: %11 | |
%11 = begin_access [deinit] [static] %10 : $*ObservationRegistrar // users: %13, %12 | |
destroy_addr %11 : $*ObservationRegistrar // id: %12 | |
end_access %11 : $*ObservationRegistrar // id: %13 | |
%14 = unchecked_ref_cast %0 : $ViewModel to $Builtin.NativeObject // user: %15 | |
return %14 : $Builtin.NativeObject // id: %15 | |
} // end sil function '$s9ViewModelAACfd' | |
// ViewModel.__deallocating_deinit | |
// Isolation: nonisolated | |
sil hidden @$s9ViewModelAACfD : $@convention(method) (@owned ViewModel) -> () { | |
// %0 "self" // users: %3, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
// function_ref ViewModel.deinit | |
%2 = function_ref @$s9ViewModelAACfd : $@convention(method) (@guaranteed ViewModel) -> @owned Builtin.NativeObject // user: %3 | |
%3 = apply %2(%0) : $@convention(method) (@guaranteed ViewModel) -> @owned Builtin.NativeObject // user: %4 | |
%4 = unchecked_ref_cast %3 : $Builtin.NativeObject to $ViewModel // user: %5 | |
dealloc_ref %4 : $ViewModel // id: %5 | |
%6 = tuple () // user: %7 | |
return %6 : $() // id: %7 | |
} // end sil function '$s9ViewModelAACfD' | |
// ViewModel.__allocating_init() | |
// Isolation: unspecified | |
sil hidden [exact_self_class] @$s9ViewModelAACABycfC : $@convention(method) (@thick ViewModel.Type) -> @owned ViewModel { | |
// %0 "$metatype" | |
bb0(%0 : $@thick ViewModel.Type): | |
%1 = alloc_ref $ViewModel // user: %3 | |
// function_ref ViewModel.init() | |
%2 = function_ref @$s9ViewModelAACABycfc : $@convention(method) (@owned ViewModel) -> @owned ViewModel // user: %3 | |
%3 = apply %2(%1) : $@convention(method) (@owned ViewModel) -> @owned ViewModel // user: %4 | |
return %3 : $ViewModel // id: %4 | |
} // end sil function '$s9ViewModelAACABycfC' | |
// ViewModel.init() | |
// Isolation: unspecified | |
sil hidden @$s9ViewModelAACABycfc : $@convention(method) (@owned ViewModel) -> @owned ViewModel { | |
// %0 "self" // users: %2, %1 | |
bb0(%0 : $ViewModel): | |
debug_value %0 : $ViewModel, let, name "self", argno 1 // id: %1 | |
%2 = end_init_let_ref %0 : $ViewModel // users: %33, %31, %23, %21, %11, %37, %10, %20, %30 | |
%3 = string_literal utf8 "Michael Long" // user: %8 | |
%4 = integer_literal $Builtin.Word, 12 // user: %8 | |
%5 = integer_literal $Builtin.Int1, -1 // user: %8 | |
%6 = metatype $@thin String.Type // user: %8 | |
// function_ref String.init(_builtinStringLiteral:utf8CodeUnitCount:isASCII:) | |
%7 = function_ref @$sSS21_builtinStringLiteral17utf8CodeUnitCount7isASCIISSBp_BwBi1_tcfC : $@convention(method) (Builtin.RawPointer, Builtin.Word, Builtin.Int1, @thin String.Type) -> @owned String // user: %8 | |
%8 = apply %7(%3, %4, %5, %6) : $@convention(method) (Builtin.RawPointer, Builtin.Word, Builtin.Int1, @thin String.Type) -> @owned String // user: %12 | |
// function_ref ViewModel.name.init | |
%9 = function_ref @$s9ViewModelAAC4nameSSvi : $@convention(thin) (@owned String, @thick ViewModel.Type) -> @out String // user: %12 | |
%10 = value_metatype $@thick ViewModel.Type, %2 : $ViewModel // user: %12 | |
%11 = ref_element_addr %2 : $ViewModel, #ViewModel._name // user: %12 | |
%12 = apply %9(%11, %8, %10) : $@convention(thin) (@owned String, @thick ViewModel.Type) -> @out String | |
%13 = string_literal utf8 "Developer" // user: %18 | |
%14 = integer_literal $Builtin.Word, 9 // user: %18 | |
%15 = integer_literal $Builtin.Int1, -1 // user: %18 | |
%16 = metatype $@thin String.Type // user: %18 | |
// function_ref String.init(_builtinStringLiteral:utf8CodeUnitCount:isASCII:) | |
%17 = function_ref @$sSS21_builtinStringLiteral17utf8CodeUnitCount7isASCIISSBp_BwBi1_tcfC : $@convention(method) (Builtin.RawPointer, Builtin.Word, Builtin.Int1, @thin String.Type) -> @owned String // user: %18 | |
%18 = apply %17(%13, %14, %15, %16) : $@convention(method) (Builtin.RawPointer, Builtin.Word, Builtin.Int1, @thin String.Type) -> @owned String // user: %22 | |
// function_ref ViewModel.title.init | |
%19 = function_ref @$s9ViewModelAAC5titleSSvi : $@convention(thin) (@owned String, @thick ViewModel.Type) -> @out String // user: %22 | |
%20 = value_metatype $@thick ViewModel.Type, %2 : $ViewModel // user: %22 | |
%21 = ref_element_addr %2 : $ViewModel, #ViewModel._title // user: %22 | |
%22 = apply %19(%21, %18, %20) : $@convention(thin) (@owned String, @thick ViewModel.Type) -> @out String | |
%23 = ref_element_addr %2 : $ViewModel, #ViewModel.ignored // user: %26 | |
%24 = integer_literal $Builtin.Int1, -1 // user: %25 | |
%25 = struct $Bool (%24 : $Builtin.Int1) // user: %26 | |
store %25 to %23 : $*Bool // id: %26 | |
%27 = integer_literal $Builtin.Int1, -1 // user: %28 | |
%28 = struct $Bool (%27 : $Builtin.Int1) // user: %32 | |
// function_ref ViewModel.hasBoilerplate.init | |
%29 = function_ref @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvi : $@convention(thin) (Bool, @thick ViewModel.Type) -> @out Bool // user: %32 | |
%30 = value_metatype $@thick ViewModel.Type, %2 : $ViewModel // user: %32 | |
%31 = ref_element_addr %2 : $ViewModel, #ViewModel._hasBoilerplate // user: %32 | |
%32 = apply %29(%31, %28, %30) : $@convention(thin) (Bool, @thick ViewModel.Type) -> @out Bool | |
%33 = ref_element_addr [immutable] %2 : $ViewModel, #ViewModel._$observationRegistrar // user: %36 | |
%34 = metatype $@thin ObservationRegistrar.Type // user: %36 | |
// function_ref ObservationRegistrar.init() | |
%35 = function_ref @$s11Observation0A9RegistrarVACycfC : $@convention(method) (@thin ObservationRegistrar.Type) -> @out ObservationRegistrar // user: %36 | |
%36 = apply %35(%33, %34) : $@convention(method) (@thin ObservationRegistrar.Type) -> @out ObservationRegistrar | |
return %2 : $ViewModel // id: %37 | |
} // end sil function '$s9ViewModelAACABycfc' | |
// ObservationRegistrar.didSet<A, B>(_:keyPath:) | |
// Isolation: unspecified | |
sil [available 14.0] @$s11Observation0A9RegistrarV6didSet_7keyPathyx_s03KeyF0Cyxq_GtAA10ObservableRzr0_lF : $@convention(method) <τ_0_0, τ_0_1 where τ_0_0 : Observable> (@in_guaranteed τ_0_0, @guaranteed KeyPath<τ_0_0, τ_0_1>, @in_guaranteed ObservationRegistrar) -> () | |
sil_vtable ViewModel { | |
#ViewModel._name!getter: (ViewModel) -> () -> String : @$s9ViewModelAAC5_name33_1E59A94D38984979103BAB9BD1543592LLSSvg // ViewModel._name.getter | |
#ViewModel._name!setter: (ViewModel) -> (String) -> () : @$s9ViewModelAAC5_name33_1E59A94D38984979103BAB9BD1543592LLSSvs // ViewModel._name.setter | |
#ViewModel._name!modify: (ViewModel) -> () -> () : @$s9ViewModelAAC5_name33_1E59A94D38984979103BAB9BD1543592LLSSvM // ViewModel._name.modify | |
#ViewModel.name!getter: (ViewModel) -> () -> String : @$s9ViewModelAAC4nameSSvg // ViewModel.name.getter | |
#ViewModel.name!setter: (ViewModel) -> (String) -> () : @$s9ViewModelAAC4nameSSvs // ViewModel.name.setter | |
#ViewModel.name!modify: (ViewModel) -> () -> () : @$s9ViewModelAAC4nameSSvM // ViewModel.name.modify | |
#ViewModel._title!getter: (ViewModel) -> () -> String : @$s9ViewModelAAC6_title33_1E59A94D38984979103BAB9BD1543592LLSSvg // ViewModel._title.getter | |
#ViewModel._title!setter: (ViewModel) -> (String) -> () : @$s9ViewModelAAC6_title33_1E59A94D38984979103BAB9BD1543592LLSSvs // ViewModel._title.setter | |
#ViewModel._title!modify: (ViewModel) -> () -> () : @$s9ViewModelAAC6_title33_1E59A94D38984979103BAB9BD1543592LLSSvM // ViewModel._title.modify | |
#ViewModel.title!getter: (ViewModel) -> () -> String : @$s9ViewModelAAC5titleSSvg // ViewModel.title.getter | |
#ViewModel.title!setter: (ViewModel) -> (String) -> () : @$s9ViewModelAAC5titleSSvs // ViewModel.title.setter | |
#ViewModel.title!modify: (ViewModel) -> () -> () : @$s9ViewModelAAC5titleSSvM // ViewModel.title.modify | |
#ViewModel.ignored!getter: (ViewModel) -> () -> Bool : @$s9ViewModelAAC7ignoredSbvg // ViewModel.ignored.getter | |
#ViewModel.ignored!setter: (ViewModel) -> (Bool) -> () : @$s9ViewModelAAC7ignoredSbvs // ViewModel.ignored.setter | |
#ViewModel.ignored!modify: (ViewModel) -> () -> () : @$s9ViewModelAAC7ignoredSbvM // ViewModel.ignored.modify | |
#ViewModel._hasBoilerplate!getter: (ViewModel) -> () -> Bool : @$s9ViewModelAAC15_hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvg // ViewModel._hasBoilerplate.getter | |
#ViewModel._hasBoilerplate!setter: (ViewModel) -> (Bool) -> () : @$s9ViewModelAAC15_hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvs // ViewModel._hasBoilerplate.setter | |
#ViewModel._hasBoilerplate!modify: (ViewModel) -> () -> () : @$s9ViewModelAAC15_hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvM // ViewModel._hasBoilerplate.modify | |
#ViewModel.hasBoilerplate!getter: (ViewModel) -> () -> Bool : @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvg // ViewModel.hasBoilerplate.getter | |
#ViewModel.hasBoilerplate!setter: (ViewModel) -> (Bool) -> () : @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvs // ViewModel.hasBoilerplate.setter | |
#ViewModel.hasBoilerplate!modify: (ViewModel) -> () -> () : @$s9ViewModelAAC14hasBoilerplate33_1E59A94D38984979103BAB9BD1543592LLSbvM // ViewModel.hasBoilerplate.modify | |
#ViewModel.access: <Member> (ViewModel) -> (KeyPath<ViewModel, Member>) -> () : @$s9ViewModelAAC6access7keyPathys03KeyE0CyABxG_tlF // ViewModel.access<A>(keyPath:) | |
#ViewModel.withMutation: <Member, MutationResult> (ViewModel) -> (KeyPath<ViewModel, Member>, () throws -> MutationResult) throws -> MutationResult : @$s9ViewModelAAC12withMutation7keyPath_q_s03KeyF0CyABxG_q_yKXEtKr0_lF // ViewModel.withMutation<A, B>(keyPath:_:) | |
#ViewModel.init!allocator: (ViewModel.Type) -> () -> ViewModel : @$s9ViewModelAACABycfC // ViewModel.__allocating_init() | |
#ViewModel.deinit!deallocator: @$s9ViewModelAACfD // ViewModel.__deallocating_deinit | |
} | |
sil_witness_table hidden ViewModel: Observable module ViewModel { | |
} | |
// Mappings from '#fileID' to '#filePath': | |
// 'ViewModel/ViewModel.swift' => 'ViewModel.swift' | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Observation | |
@Observable | |
class ViewModel { | |
var name = "Michael Long" | |
var title = "Developer" | |
@ObservationIgnored var ignored: Bool = true | |
private var hasBoilerplate: Bool = true | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment