File tree 2 files changed +5
-4
lines changed
stdlib/public/RuntimeModule
2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -502,7 +502,7 @@ protocol DwarfSource {
502
502
503
503
}
504
504
505
- struct DwarfReader < S: DwarfSource > {
505
+ struct DwarfReader < S: DwarfSource & AnyObject > {
506
506
507
507
typealias Source = S
508
508
typealias Address = UInt64
@@ -513,7 +513,7 @@ struct DwarfReader<S: DwarfSource> {
513
513
var end : Address { return base + size }
514
514
}
515
515
516
- var source : Source
516
+ unowned var source : Source
517
517
518
518
struct AbbrevInfo {
519
519
var tag : Dwarf_Tag
Original file line number Diff line number Diff line change @@ -1793,8 +1793,9 @@ final class ElfImage<SomeElfTraits: ElfTraits>
1793
1793
}
1794
1794
}
1795
1795
1796
- private lazy var dwarfReader
1797
- = try ? DwarfReader ( source: self , shouldSwap: header. shouldByteSwap)
1796
+ private lazy var dwarfReader = { [ unowned self] in
1797
+ try ? DwarfReader ( source: self , shouldSwap: header. shouldByteSwap)
1798
+ } ( )
1798
1799
1799
1800
typealias CallSiteInfo = DwarfReader < ElfImage > . CallSiteInfo
1800
1801
You can’t perform that action at this time.
0 commit comments