@@ -36,19 +36,6 @@ struct TupleBuilder {
36
36
return ( t1, t2, t3, t4, t5)
37
37
}
38
38
39
- static func buildDo< T1> ( _ t1: T1 ) -> Do < ( T1 ) > {
40
- . init( value: t1)
41
- }
42
-
43
- static func buildDo< T1, T2> ( _ t1: T1 , _ t2: T2 ) -> Do < ( T1 , T2 ) > {
44
- . init( value: ( t1, t2) )
45
- }
46
-
47
- static func buildDo< T1, T2, T3> ( _ t1: T1 , _ t2: T2 , _ t3: T3 )
48
- -> Do < ( T1 , T2 , T3 ) > {
49
- . init( value: ( t1, t2, t3) )
50
- }
51
-
52
39
static func buildIf< T> ( _ value: T ? ) -> T ? { return value }
53
40
54
41
static func buildEither< T, U> ( first value: T ) -> Either < T , U > {
@@ -65,7 +52,7 @@ func tuplify<T>(_ cond: Bool, @TupleBuilder body: (Bool) -> T) {
65
52
print ( body ( cond) )
66
53
}
67
54
68
- // CHECK: (17, 3.14159, "Hello, DSL", main.Do<(Swift.Array<Swift.String>, Swift.Int)>(value: ( ["nested", "do"], 6) ), Optional((2.71828, ["if", "stmt"])))
55
+ // CHECK: (17, 3.14159, "Hello, DSL", ( ["nested", "do"], 6), Optional((2.71828, ["if", "stmt"])))
69
56
let name = " dsl "
70
57
tuplify ( true ) {
71
58
17
@@ -664,7 +651,6 @@ struct TupleBuilderWithOpt {
664
651
return ( t1, t2, t3, t4, t5)
665
652
}
666
653
667
- static func buildDo< T> ( _ value: T ) -> T { return value }
668
654
static func buildOptional< T> ( _ value: T ? ) -> T ? { return value }
669
655
670
656
static func buildEither< T, U> ( first value: T ) -> Either < T , U > {
@@ -718,7 +704,6 @@ protocol FunctionBuilderProtocol {
718
704
719
705
static func buildExpression( _ expression: Expression ) -> Component
720
706
static func buildBlock( _ components: Component ... ) -> Component
721
- static func buildDo( _ components: Component ... ) -> Component
722
707
static func buildOptional( _ optional: Component ? ) -> Component
723
708
static func buildArray( _ components: [ Component ] ) -> Component
724
709
static func buildLimitedAvailability( _ component: Component ) -> Component
@@ -729,7 +714,6 @@ protocol FunctionBuilderProtocol {
729
714
extension FunctionBuilderProtocol {
730
715
static func buildExpression( _ expression: Expression ) -> Component { . expression( expression) }
731
716
static func buildBlock( _ components: Component ... ) -> Component { . block( components) }
732
- static func buildDo( _ components: Component ... ) -> Component { . block( components) }
733
717
static func buildOptional( _ optional: Component ? ) -> Component { . optional( optional) }
734
718
static func buildArray( _ components: [ Component ] ) -> Component { . block( components) }
735
719
static func buildLimitedAvailability( _ component: Component ) -> Component { component }
0 commit comments