File tree 2 files changed +31
-13
lines changed
2 files changed +31
-13
lines changed Original file line number Diff line number Diff line change @@ -10,12 +10,15 @@ macro {
10
10
·chain(
11
11
async,
12
12
·optional(
13
- ·either(
14
- public,
15
- protected,
16
- private
13
+ ·repeat(
14
+ ·either(
15
+ public,
16
+ protected,
17
+ private,
18
+ static
19
+ )·modifier
17
20
)
18
- )·visibility ,
21
+ )·modifiers ,
19
22
function,
20
23
·ns()·function,
21
24
·token("("),
@@ -52,19 +55,22 @@ macro {
52
55
·token(";")
53
56
)
54
57
} >> {··trim(
55
- ·visibility function ·function(·args ···(, ) { ·arg ··· { ·argType ·argName ·argAssignmentEq ·argAssignmentVal } }): \Amp\Promise;
58
+ ··trim(·modifiers ···( ) { ·modifier }) function ·function(·args ···(, ) { ·arg ··· { ·argType ·argName ·argAssignmentEq ·argAssignmentVal } }): \Amp\Promise;
56
59
)}
57
60
58
61
macro ·recursion {
59
62
·chain(
60
63
async,
61
64
·optional(
62
- ·either(
63
- public,
64
- protected,
65
- private
65
+ ·repeat(
66
+ ·either(
67
+ public,
68
+ protected,
69
+ private,
70
+ static
71
+ )·modifier
66
72
)
67
- )·visibility ,
73
+ )·modifiers ,
68
74
function,
69
75
·ns()·function,
70
76
·token("("),
@@ -161,7 +167,7 @@ macro ·recursion {
161
167
}
162
168
} >> {··trim(
163
169
·scope ?·{
164
- ·visibility function ·function(·args ···(, ) { ·arg ··· { ·argType ·argName ·argAssignmentEq ·argAssignmentVal } }): \Amp\Promise
170
+ ··trim(·modifiers ···( ) { ·modifier }) function ·function(·args ···(, ) { ·arg ··· { ·argType ·argName ·argAssignmentEq ·argAssignmentVal } }): \Amp\Promise
165
171
{
166
172
return call_user_func(PRE_ASYNC_WRAPPER, function () use (·scope ···(, ) { &·var }) {
167
173
·body ·yields ?·{yield;}
@@ -170,7 +176,7 @@ macro ·recursion {
170
176
}
171
177
172
178
·simple ?·{
173
- ·visibility function ·function(·args ···(, ) { ·arg ··· { ·argType ·argName ·argAssignmentEq ·argAssignmentVal } }): \Amp\Promise
179
+ ··trim(·modifiers ···( ) { ·modifier }) function ·function(·args ···(, ) { ·arg ··· { ·argType ·argName ·argAssignmentEq ·argAssignmentVal } }): \Amp\Promise
174
180
{
175
181
return call_user_func(PRE_ASYNC_WRAPPER, function () {
176
182
·body ·yields ?·{yield;}
Original file line number Diff line number Diff line change @@ -20,6 +20,11 @@ class AsyncClass
20
20
{
21
21
return "boo!" ;
22
22
}
23
+
24
+ async public static function complex ()
25
+ {
26
+
27
+ }
23
28
}
24
29
25
30
$first = async function () {
@@ -58,6 +63,13 @@ class AsyncClass
58
63
yield ;
59
64
});
60
65
}
66
+
67
+ public static function complex (): \Amp \Promise
68
+ {
69
+ return call_user_func (PRE_ASYNC_WRAPPER , function () {
70
+ yield ;
71
+ });
72
+ }
61
73
}
62
74
63
75
$first = function (): \Amp \Promise {
You can’t perform that action at this time.
0 commit comments