Skip to content

Commit 1f95f92

Browse files
committed
Tweak type annotation to include null
1 parent 6b9dd7a commit 1f95f92

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

CHANGELOG.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ Version 4.2.0-dev
33

44
### Added
55

6-
* [PHP 7.4] Add support for typed properties through a new `type` subnode of `Stmt\Property`. (#567)
6+
* [PHP 7.4] Add support for typed properties through a new `type` subnode of `Stmt\Property`.
7+
Additionally `Builder\Property` now has a `setType()` method. (#567)
78
* Add `kind` attribute to `Cast\Double_`, which allows to distinguish between `(float)`,
89
`(double)` and `(real)`. The form of the cast will be preserved by the pretty printer. (#565)
910

lib/PhpParser/Builder/Property.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,7 @@ class Property implements PhpParser\Builder
1717
protected $default = null;
1818
protected $attributes = [];
1919

20-
/**
21-
* @var Identifier|Name|NullableType
22-
*/
20+
/** @var null|Identifier|Name|NullableType */
2321
protected $type;
2422

2523
/**

0 commit comments

Comments
 (0)