File tree Expand file tree Collapse file tree 2 files changed +4
-1
lines changed
Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -18,8 +18,9 @@ package struct Framebuffer<Depth: UnsignedInteger>: ~Copyable {
1818 /// The number of pixels of Framebuffer.
1919 private let pixelCount : Int
2020 /// Framebuffer.
21+ @inline ( always)
22+ @export ( implementation)
2123 package var buffer : MutableSpan < Depth > {
22- @inline ( always)
2324 mutating get { unsafe . init ( _unsafeStart: self . baseAddress, count: self . pixelCount) }
2425 }
2526
Original file line number Diff line number Diff line change @@ -15,13 +15,15 @@ let mboxEmpty: UInt32 = 0x4000_0000
1515struct Mbox : ~ Copyable {
1616 private var storage : [ 36 of UInt32 ] = . init( repeating: 0 )
1717
18+ @inline ( always)
1819 private mutating func volatilePointer( at i: Int ) -> VolatileMappedRegister < UInt32 > {
1920 unsafe withUnsafePointer( to: & self . storage [ i] ) { ptr in
2021 unsafe VolatileMappedRegister ( unsafeBitPattern: UInt ( bitPattern: ptr) )
2122 }
2223 }
2324
2425 @inline ( always)
26+ @export ( implementation)
2527 subscript( _ i: Int ) -> UInt32 {
2628 mutating get { self . volatilePointer ( at: i) . load ( ) }
2729 set { self . volatilePointer ( at: i) . store ( newValue) }
You can’t perform that action at this time.
0 commit comments