File tree 4 files changed +9
-11
lines changed
Dependencies/Engine/EngineCore
Sources/_SwiftUIZ_A/Intramodular
4 files changed +9
-11
lines changed Original file line number Diff line number Diff line change 2
2
// Copyright (c) Nathan Tannar
3
3
//
4
4
5
+ import Swallow
6
+
5
7
/// A type that wraps the conformance of protocol `P` for a given type.
6
8
///
7
9
/// See also:
@@ -14,7 +16,7 @@ public struct ProtocolConformance<P: TypeDescriptor> {
14
16
public init ? ( _ type: Any . Type ) {
15
17
let metadata = unsafeBitCast ( type, to: UnsafeRawPointer . self)
16
18
let desc = P . descriptor
17
- guard let conformance = swift_conformsToProtocol ( metadata, desc) else {
19
+ guard let conformance = _swift_conformsToProtocol ( metadata, desc) else {
18
20
return nil
19
21
}
20
22
self . metadata = metadata
@@ -39,9 +41,3 @@ extension TypeDescriptor {
39
41
return ProtocolConformance ( type)
40
42
}
41
43
}
42
-
43
- @_silgen_name ( " swift_conformsToProtocol " )
44
- func swift_conformsToProtocol(
45
- _ type: UnsafeRawPointer ,
46
- _ descriptor: UnsafeRawPointer
47
- ) -> UnsafeRawPointer ?
Original file line number Diff line number Diff line change 3
3
//
4
4
5
5
import Swallow
6
+ import SwallowMacrosClient
6
7
import SwiftUI
7
8
8
9
@dynamicMemberLookup
@@ -49,7 +50,7 @@ public struct _ConstantOrBinding<Value>: _SwiftUIZ_DynamicProperty {
49
50
public var binding : any _SwiftUIX_BindingType < Value > {
50
51
get throws {
51
52
guard case . binding( let binding) = base else {
52
- throw _PlaceholderError ( )
53
+ # throw
53
54
}
54
55
55
56
return binding
Original file line number Diff line number Diff line change @@ -153,8 +153,8 @@ public enum _DynamicSceneInitializers {
153
153
}
154
154
155
155
try _warnOnThrow {
156
- try _tryAssert ( parameters. idType == nil )
157
- try _tryAssert ( parameters. id == nil )
156
+ try #assert ( parameters. idType == nil )
157
+ try #assert ( parameters. id == nil )
158
158
}
159
159
160
160
guard let value = parameters. value as? Value else {
Original file line number Diff line number Diff line change 3
3
//
4
4
5
5
import Swallow
6
+ import SwallowMacrosClient
6
7
import SwiftUI
7
8
8
9
@MainActor
@@ -49,7 +50,7 @@ extension _SwiftUIZ_Scene {
49
50
} else if let body = body as? _DonateDynamicSceneInitializer {
50
51
return body. _resolve ( )
51
52
} else {
52
- throw _PlaceholderError ( )
53
+ # throw
53
54
}
54
55
}
55
56
}
You can’t perform that action at this time.
0 commit comments