Skip to content

Commit 3763238

Browse files
committed
Revert "Add initial support for callable syntax"
This reverts commit d33f710.
1 parent 82f572c commit 3763238

File tree

3 files changed

+1
-147
lines changed

3 files changed

+1
-147
lines changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"keywords": ["module", "xp"],
88
"require" : {
99
"xp-framework/core": "^10.0 | ^9.0 | ^8.0 | ^7.0",
10-
"xp-framework/ast": "dev-feature/first_class_callable_syntax as 7.4.0",
10+
"xp-framework/ast": "^7.3",
1111
"php" : ">=7.0.0"
1212
},
1313
"require-dev" : {

src/main/php/lang/ast/emit/PHP.class.php

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -988,13 +988,6 @@ protected function emitNewClass($result, $new) {
988988
array_shift($result->type);
989989
}
990990

991-
protected function emitCallable($result, $callable) {
992-
$t= $result->temp();
993-
$result->out->write('fn(...'.$t.') => ');
994-
$this->emitOne($result, $callable->expression);
995-
$result->out->write('(... '.$t.')');
996-
}
997-
998991
protected function emitInvoke($result, $invoke) {
999992
$this->emitOne($result, $invoke->expression);
1000993
$result->out->write('(');

src/test/php/lang/ast/unittest/emit/CallableSyntaxTest.class.php

Lines changed: 0 additions & 139 deletions
This file was deleted.

0 commit comments

Comments
 (0)