forked from nikic/php-ast
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpackage.xml
573 lines (572 loc) · 20.9 KB
/
package.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
<?xml version="1.0" encoding="UTF-8"?>
<package packagerversion="1.9.1" version="2.0" xmlns="http://pear.php.net/dtd/package-2.0" xmlns:tasks="http://pear.php.net/dtd/tasks-1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://pear.php.net/dtd/tasks-1.0 http://pear.php.net/dtd/tasks-1.0.xsd http://pear.php.net/dtd/package-2.0 http://pear.php.net/dtd/package-2.0.xsd">
<name>ast</name>
<channel>pecl.php.net</channel>
<summary>Extension exposing PHP 7 abstract syntax tree</summary>
<description>php-ast exports the AST internally used by PHP 7.
php-ast is significantly faster than PHP-Parser, because the AST construction is implemented in C.
However, php-ast may only parse code that is syntactically valid on the version of PHP it runs on.</description>
<lead>
<name>Nikita Popov</name>
<user>nikic</user>
<email>[email protected]</email>
<active>yes</active>
</lead>
<lead>
<name>Tyson Andre</name>
<user>tandre</user>
<email>[email protected]</email>
<active>yes</active>
</lead>
<date>2022-02-12</date>
<version>
<release>1.0.17dev</release>
<api>1.0.17dev</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Change documentation files to properly namespace attributes as `#[\AllowDynamicProperties]`. The reflection attributes are already correct.
</notes>
<contents>
<dir name="/">
<file name="config.m4" role="src" />
<file name="config.w32" role="src" />
<file name="util.php" role="doc" />
<file name="ast.c" role="src" />
<file name="ast_data.c" role="src" />
<file name="ast_arginfo.h" role="src" />
<file name="ast_str_defs.h" role="src" />
<file name="ast_stub.php" role="doc" />
<file name="LICENSE" role="doc" />
<file name="php_ast.h" role="src" />
<file name="README.md" role="doc" />
<file name="php_ast.h" role="src" />
<dir name="tests">
<file name="001.phpt" role="test" />
<file name="array_destructuring_old.phpt" role="test" />
<file name="array_destructuring.phpt" role="test" />
<file name="assign_ops.phpt" role="test" />
<file name="ast_dump_with_exclude_doc.phpt" role="test" />
<file name="ast_dump_with_linenos.phpt" role="test" />
<file name="attributes_01.phpt" role="test" />
<file name="attributes_02.phpt" role="test" />
<file name="binary_ops.phpt" role="test" />
<file name="by_ref_destructuring.phpt" role="test" />
<file name="class_consts.phpt" role="test" />
<file name="class_consts_80.phpt" role="test" />
<file name="class_name_version_50.phpt" role="test" />
<file name="class_name_version_70.phpt" role="test" />
<file name="class_on_objects.phpt" role="test" />
<file name="class.phpt" role="test" />
<file name="class_type_85.phpt" role="test" />
<file name="class_types.phpt" role="test" />
<file name="closure_use_vars.phpt" role="test" />
<file name="coalesce.phpt" role="test" />
<file name="concat.phpt" role="test" />
<file name="constructor.phpt" role="test" />
<file name="decl_ids.phpt" role="test" />
<file name="decl_normalization.phpt" role="test" />
<file name="empty_file.php" role="test" />
<file name="empty_file_parse.phpt" role="test" />
<file name="eval_include.phpt" role="test" />
<file name="functions_dont_use.phpt" role="test" />
<file name="generator_flag.phpt" role="test" />
<file name="get_kind_name.phpt" role="test" />
<file name="get_supported_versions.phpt" role="test" />
<file name="invalid_file.php" role="test" />
<file name="magic_constants.phpt" role="test" />
<file name="match_expression.phpt" role="test" />
<file name="metadata.phpt" role="test" />
<file name="mixed_type.phpt" role="test" />
<file name="multi_catch.phpt" role="test" />
<file name="multiple_final_modifiers.phpt" role="test" />
<file name="named_children.phpt" role="test" />
<file name="name_node.phpt" role="test" />
<file name="nested_stmt_lists.phpt" role="test" />
<file name="never_return_type.phpt" role="test" />
<file name="node_constructor_throw.phpt" role="test" />
<file name="nop_statements.phpt" role="test" />
<file name="nullable_types.phpt" role="test" />
<file name="object_type.phpt" role="test" />
<file name="params.phpt" role="test" />
<file name="parse_code_parse_error.phpt" role="test" />
<file name="parse_file_not_existing.phpt" role="test" />
<file name="parse_file_parse_error.phpt" role="test" />
<file name="parse_file.phpt" role="test" />
<file name="php74_ast_assign_coalesce.phpt" role="test" />
<file name="php74_dim_alternative_syntax.phpt" role="test" />
<file name="php74_ordinary_class.phpt" role="test" />
<file name="php74_parenthesized_conditional.phpt" role="test" />
<file name="php74_type_hints.phpt" role="test" />
<file name="php80_named_params.phpt" role="test" />
<file name="php80_noncapturing_catch.phpt" role="test" />
<file name="php80_nullsafe_operator.phpt" role="test" />
<file name="php80_promotion.phpt" role="test" />
<file name="php80_static_type.phpt" role="test" />
<file name="php80_union_types_false.phpt" role="test" />
<file name="php80_union_types_nullable.phpt" role="test" />
<file name="php80_union_types.phpt" role="test" />
<file name="php81_enums.phpt" role="test" />
<file name="php81_first_class_callable_support.phpt" role="test" />
<file name="php81_final_class_const.phpt" role="test" />
<file name="php81_intersection_types.phpt" role="test" />
<file name="php81_readonly.phpt" role="test" />
<file name="php82_metadata.phpt" role="test" />
<file name="prop_doc_comments.phpt" role="test" />
<file name="short_arrow_function.phpt" role="test" />
<file name="short_arrow_function_return.phpt" role="test" />
<file name="stmt_list.phpt" role="test" />
<file name="try_catch_finally.phpt" role="test" />
<file name="type_hints.phpt" role="test" />
<file name="unary_ops.phpt" role="test" />
<file name="use_declarations.phpt" role="test" />
<file name="valid_file.php" role="test" />
<file name="version_errors.phpt" role="test" />
<file name="zpp_errors.phpt" role="test" />
</dir>
</dir>
</contents>
<dependencies>
<required>
<php>
<min>7.0.0</min>
</php>
<pearinstaller>
<min>1.10.0</min>
</pearinstaller>
</required>
</dependencies>
<providesextension>ast</providesextension>
<extsrcrelease />
<changelog>
<release>
<date>2021-11-27</date>
<version>
<release>1.0.16</release>
<api>1.0.16</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Optimize instantiating properties of ast\Node and ast\Metadata.
- Document that ast\Node implements `#[AllowDynamicProperties]` in php 8.2
</notes>
</release>
<release>
<date>2021-11-27</date>
<version>
<release>1.0.15</release>
<api>1.0.15</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Allow ast\Node to have dynamic properties without emitting a notice in PHP 8.2.
</notes>
</release>
<release>
<date>2021-07-24</date>
<version>
<release>1.0.14</release>
<api>1.0.14</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Support php 8.1 readonly properties with the flag 'MODIFIER_READONLY'
- Support php 8.1 first-class callable syntax, add the node kind 'AST_CALLABLE_CONVERT'
- Change the current AST version from 80 to the new version 90. AST version 85 is no longer experimental.
</notes>
</release>
<release>
<date>2021-07-08</date>
<version>
<release>1.0.13</release>
<api>1.0.13</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Indicate in metadata that 'AST_CLASS_CONST_GROUP' and 'AST_CLASS_CONST_DECL' can have 'MODIFIER_FINAL'
(and any modifier a class element can have, to reflect what the parser can actually parse)
- Support php 8.1 intersection types, add the node kind 'AST_TYPE_INTERSECTION'
</notes>
</release>
<release>
<date>2021-05-16</date>
<version>
<release>1.0.12</release>
<api>1.0.12</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Support parsing 'docComment' on php 8.1 enum cases
- Indicate in metadata that 'AST_CLASS_CONST_GROUP' and 'AST_CLASS_CONST_DECL' can have MODIFIER_FINAL
</notes>
</release>
<release>
<date>2021-04-20</date>
<version>
<release>1.0.11</release>
<api>1.0.11</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Add the experimental AST version 85.
- Support php 8.1 enums, add 'type' (for enum type) to AST_CLASS nodes in AST version 85+.
- Support php 8.1 'never' return type.
</notes>
</release>
<release>
<date>2020-09-12</date>
<version>
<release>1.0.10</release>
<api>1.0.10</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Support attributes syntax change (`#[...]`) in php 8.0.0RC1.
- Change the current AST version from 70 to 80. AST version 80 is no longer experimental.
- Add `ReflectionParameter` defaults for `ast\parse_code` and `ast\get_supported_versions` in php 8.
- Add parameter types and return types to reflection for various global functions.
php-ast was already throwing a `TypeError` when invalid parameter types were received.
- Always throw instead of warning when invalid parameters are passed to the ast\Node constructor.
</notes>
</release>
<release>
<date>2020-09-02</date>
<version>
<release>1.0.9</release>
<api>1.0.9</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Support API change in php 8.0.0beta3.
</notes>
</release>
<release>
<date>2020-08-04</date>
<version>
<release>1.0.8</release>
<api>1.0.8</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Recommend using the new constant `ast\flags\PARAM_MODIFIER_*` when checking if parameters use constructor property promotion.
The values of `ast\flags\MODIFIER_*` and `ast\flags\PARAM_VARIADIC` had some overlap in some php 7 versions.
The new constants will have the same values as `ast\flags\MODIFIER_*` in PHP 8.0+, but different values in PHP 7
(and these flags will never be set in php 7).
- Support PHP 8.0's named arguments.
- Support PHP 8.0's nullsafe operator (`?->`).
</notes>
</release>
<release>
<date>2020-07-11</date>
<version>
<release>1.0.7</release>
<api>1.0.7</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Add the experimental AST version 80
- In AST version 80, support returning `mixed` types as an `AST_TYPE` with type `TYPE_MIXED` instead of an `AST_NAME`.
- In AST version 80, support PHP 8.0 attributes for declarations.
- Support PHP 8.0's Match expressions.
- Support PHP 8.0 constructor property promotion, and allow indicating visibility on AST nodes.
Note that `MODIFIER_PUBLIC` and `ast\AST_PARAM` modifiers had overlap in php 7.4,
so the `MODIFIER_*` modifiers are only included in the provided metadata for php 8.0+
</notes>
</release>
<release>
<date>2020-02-22</date>
<version>
<release>1.0.6</release>
<api>1.0.6</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Support TYPE_STATIC for the php 8.0 static return type.
</notes>
</release>
<release>
<date>2019-11-23</date>
<version>
<release>1.0.5</release>
<api>1.0.5</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Add ast\flags\TYPE_FALSE to support PHP 8.0 Union Types.
</notes>
</release>
<release>
<date>2019-11-10</date>
<version>
<release>1.0.4</release>
<api>1.0.4</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Add AST_TYPE_UNION to support PHP 8.0 Union Types.
</notes>
</release>
<release>
<date>2019-07-27</date>
<version>
<release>1.0.3</release>
<api>1.0.3</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Fix build error in php 7.4.0alpha3.
- Add `DIM_ALTERNATIVE_SYNTAX` as a flag of `AST_DIM` for `$x{'offset'}` (for php 7.4+)
- Add `PARENTHESIZED_CONDITIONAL` as a flag of `AST_CONDITIONAL` for `($a ? $b : $c)` (for php 7.4+)
- Bugfix: Make `ast\kind_uses_flags(ast\AST_ARROW_FUNC)` true in php 7.3 and lower.
</notes>
</release>
<release>
<date>2019-06-30</date>
<version>
<release>1.0.2</release>
<api>1.0.2</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Fix compatibility with (currently) PHP 7.4 and PHP 8.0.
- Support AST_ARROW_FUNC for PHP 7.4.
- Make $version a required parameter for `ast\parse_*`. Previously, the absence would throw a LogicException.
- Make AST version 70 the current version.
</notes>
</release>
<release>
<date>2019-02-11</date>
<version>
<release>1.0.1</release>
<api>1.0.1</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Fix compatibility with (currently) PHP 7.4 and PHP 8.0.
- Support BINARY_COALESCE as a flag of AST_ASSIGN_OP for the `??=` operator added in PHP 7.4.
- Add AST version 70 (experimental):
- Version 70 adds AST_PROP_GROUP with type information for property groups.
- Version 70 adds AST_CLASS_NAME for `Foo::class`. Previously this used AST_CLASS_CONST
</notes>
</release>
<release>
<date>2018-10-21</date>
<version>
<release>1.0.0</release>
<api>1.0.0</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
This release is the same as version 0.1.7 with obsolete and deprecated functionality removed.
- Removed AST versions prior to version 50.
- Removed ast\Node\Decl class, which is no longer used.
- Removed AST kinds AST_AND, AST_COALESCE, AST_GREATER, AST_GREATER_EQUAL, AST_OR, AST_SILENCE,
AST_UNARY_MINUS, and AST_UNARY_PLUS, which are no longer used.
- Removed ASSIGN_* AST flags, which are no longer used.
</notes>
</release>
<release>
<date>2018-10-06</date>
<version>
<release>0.1.7</release>
<api>0.1.7</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Added AST version 60 with the following changes:
- `AST_FUNC_DECL` and `AST_METHOD` no longer generate a `uses` child. Previously this child was
always `null`.
- `AST_CONST_ELEM` now always has a `docComment` child. Previously it was absent on PHP 7.0.
On PHP 7.0 the value is always `null`.
- Added `ARRAY_ELEM_REF` flag, which is used by `AST_ARRAY_ELEM` for by-reference array elements
and (since PHP 7.3) for by-reference destructuring. Previously this flag was represented simply
by the value `1`.
- Deprecated AST versions 40 and 45.
- Fix build against PHP 7.4-dev.
</notes>
</release>
<release>
<date>2017-10-08</date>
<version>
<release>0.1.6</release>
<api>0.1.6</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Added ast\get_metadata() function, which returns an array of ast\Metadata objects, one for each
AST kind. The metadata contains information such as the supported flags for the kind.
- Added ast\get_supported_versions() function, which provides an array of currently supported AST
versions.
</notes>
</release>
<release>
<date>2017-07-19</date>
<version>
<release>0.1.5</release>
<api>0.1.5</api>
</version>
<stability>
<release>stable</release>
<api>stable</api>
</stability>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
- Fix issue #51: Make nullable array/callable have a flag of 0 in inner element, in version 40.
- Added a constructor for the ast\Node class.
- Added ast\flags\FUNC_GENERATOR constant, which is used since PHP 7.1.
- Added ast\flags\FUNC_RETURNS_REF constant, intended to supersede ast\flags\RETURNS_REF.
- Added ast\flags\CLOSURE_USE_REF constant, used by AST_CLOSURE_VAR nodes. Previously "1" was used.
- Added version 45 with the following changes (PHP 7.2 support):
- An `object` type annotation now returns an `AST_TYPE` with `TYPE_OBJECT` flag, rather than
treating `object` as a class name.
- Added version 50 with the following changes:
- `ast\Node\Decl` nodes are no longer generated. AST kinds `AST_FUNCTION`, `AST_METHOD`,
`AST_CLOSURE` and `AST_CLASS` now also use the normal `ast\Node` class. The `name` and
`docComment` properties are now represented as children. The `endLineno` is still represented as
an (undeclared) property.
- An integer `__declId` has been added to declaration nodes of kind `AST_FUNCTION`, `AST_METHOD`,
`AST_CLOSURE` and `AST_CLASS`. The `__declId` uniquely identifies a declaration within the
parsed code and will remain the same if the code is parsed again. This is useful to distinguish
closures declared on the same line, or multiple conditional declarations using the same name.
The ID is not unique across different codes/files.
- `\ast\parse_file` will now consistently return an empty statement list (similar to
`\ast\parse_code`) if it is was passed a zero-byte file. Previously, it would return `null`.
</notes>
</release>
<release>
<date>2017-01-25</date>
<version>
<release>0.1.4</release>
<api>0.1.4</api>
</version>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
0.1.4 release
</notes>
</release>
<release>
<date>2017-01-18</date>
<version>
<release>0.1.3</release>
<api>0.1.3</api>
</version>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
0.1.3 release
</notes>
</release>
<release>
<date>2017-08-04</date>
<version>
<release>0.1.2</release>
<api>0.1.2</api>
</version>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
0.1.2 release
</notes>
</release>
<release>
<date>2017-12-04</date>
<version>
<release>0.1.1</release>
<api>0.1.1</api>
</version>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
0.1.1 release
</notes>
</release>
<release>
<date>2017-12-04</date>
<version>
<release>0.1.0</release>
<api>0.1.0</api>
</version>
<license uri="https://github.com/nikic/php-ast/blob/master/LICENSE">BSD-3-Clause</license>
<notes>
0.1.0 release
</notes>
</release>
</changelog>
</package>