@@ -1022,7 +1022,7 @@ public function getNonNamespacedName(): string {
1022
1022
}
1023
1023
1024
1024
public function getDeclarationName (): string {
1025
- return implode ('_ ' , $ this ->name ->parts );
1025
+ return implode ('_ ' , $ this ->name ->getParts () );
1026
1026
}
1027
1027
1028
1028
public function getFunctionName (): string {
@@ -1034,12 +1034,12 @@ public function getDeclaration(): string {
1034
1034
}
1035
1035
1036
1036
public function getArgInfoName (): string {
1037
- $ underscoreName = implode ('_ ' , $ this ->name ->parts );
1037
+ $ underscoreName = implode ('_ ' , $ this ->name ->getParts () );
1038
1038
return "arginfo_ $ underscoreName " ;
1039
1039
}
1040
1040
1041
1041
public function getMethodSynopsisFilename (): string {
1042
- return implode ('_ ' , $ this ->name ->parts );
1042
+ return implode ('_ ' , $ this ->name ->getParts () );
1043
1043
}
1044
1044
1045
1045
public function getNameForAttributes (): string {
@@ -1073,7 +1073,7 @@ public function __construct(Name $className, string $methodName) {
1073
1073
}
1074
1074
1075
1075
public function getDeclarationClassName (): string {
1076
- return implode ('_ ' , $ this ->className ->parts );
1076
+ return implode ('_ ' , $ this ->className ->getParts () );
1077
1077
}
1078
1078
1079
1079
public function getDeclaration (): string {
@@ -2496,13 +2496,13 @@ public function getRegistration(iterable $allConstInfos): string
2496
2496
{
2497
2497
$ params = [];
2498
2498
foreach ($ this ->extends as $ extends ) {
2499
- $ params [] = "zend_class_entry *class_entry_ " . implode ("_ " , $ extends ->parts );
2499
+ $ params [] = "zend_class_entry *class_entry_ " . implode ("_ " , $ extends ->getParts () );
2500
2500
}
2501
2501
foreach ($ this ->implements as $ implements ) {
2502
- $ params [] = "zend_class_entry *class_entry_ " . implode ("_ " , $ implements ->parts );
2502
+ $ params [] = "zend_class_entry *class_entry_ " . implode ("_ " , $ implements ->getParts () );
2503
2503
}
2504
2504
2505
- $ escapedName = implode ("_ " , $ this ->name ->parts );
2505
+ $ escapedName = implode ("_ " , $ this ->name ->getParts () );
2506
2506
2507
2507
$ code = '' ;
2508
2508
@@ -2527,7 +2527,7 @@ public function getRegistration(iterable $allConstInfos): string
2527
2527
$ code .= "\tzend_class_entry *class_entry = zend_register_internal_enum( \"$ name \", $ backingType, class_ {$ escapedName }_methods); \n" ;
2528
2528
} else {
2529
2529
$ code .= "\tzend_class_entry ce, *class_entry; \n\n" ;
2530
- if (count ($ this ->name ->parts ) > 1 ) {
2530
+ if (count ($ this ->name ->getParts () ) > 1 ) {
2531
2531
$ className = $ this ->name ->getLast ();
2532
2532
$ namespace = addslashes ((string ) $ this ->name ->slice (0 , -1 ));
2533
2533
@@ -2548,7 +2548,7 @@ public function getRegistration(iterable $allConstInfos): string
2548
2548
2549
2549
$ implements = array_map (
2550
2550
function (Name $ item ) {
2551
- return "class_entry_ " . implode ("_ " , $ item ->parts );
2551
+ return "class_entry_ " . implode ("_ " , $ item ->getParts () );
2552
2552
},
2553
2553
$ this ->type === "interface " ? $ this ->extends : $ this ->implements
2554
2554
);
@@ -2917,7 +2917,7 @@ private static function createOoElement(
2917
2917
}
2918
2918
2919
2919
public static function getClassSynopsisFilename (Name $ name ): string {
2920
- return strtolower (str_replace ("_ " , "- " , implode ('- ' , $ name ->parts )));
2920
+ return strtolower (str_replace ("_ " , "- " , implode ('- ' , $ name ->getParts () )));
2921
2921
}
2922
2922
2923
2923
public static function getClassSynopsisReference (Name $ name ): string {
@@ -3797,8 +3797,8 @@ function parseStubFile(string $code): FileInfo {
3797
3797
$ nodeTraverser = new PhpParser \NodeTraverser ;
3798
3798
$ nodeTraverser ->addVisitor (new PhpParser \NodeVisitor \NameResolver );
3799
3799
$ prettyPrinter = new class extends Standard {
3800
- protected function pName_FullyQualified (Name \FullyQualified $ node ) {
3801
- return implode ('\\' , $ node ->parts );
3800
+ protected function pName_FullyQualified (Name \FullyQualified $ node ): string {
3801
+ return implode ('\\' , $ node ->getParts () );
3802
3802
}
3803
3803
};
3804
3804
@@ -4102,7 +4102,7 @@ function generateFunctionEntries(?Name $className, array $funcInfos, ?string $co
4102
4102
4103
4103
$ functionEntryName = "ext_functions " ;
4104
4104
if ($ className ) {
4105
- $ underscoreName = implode ("_ " , $ className ->parts );
4105
+ $ underscoreName = implode ("_ " , $ className ->getParts () );
4106
4106
$ functionEntryName = "class_ {$ underscoreName }_methods " ;
4107
4107
}
4108
4108
@@ -4685,7 +4685,7 @@ function initPhpParser() {
4685
4685
}
4686
4686
4687
4687
$ isInitialized = true ;
4688
- $ version = "4.15.1 " ;
4688
+ $ version = "5.0.0alpha3 " ;
4689
4689
$ phpParserDir = __DIR__ . "/PHP-Parser- $ version " ;
4690
4690
if (!is_dir ($ phpParserDir )) {
4691
4691
installPhpParser ($ version , $ phpParserDir );
0 commit comments