1--TEST-- 2Doc comments on properties 3--FILE-- 4<?php 5 6require __DIR__ . '/../util.php'; 7 8$code = <<<'PHP' 9<?php 10class A { 11 /** docComment $a */ 12 public $a; 13 14 public 15 /** docComment $b */ 16 $b, 17 /** docComment $c */ 18 $c 19 ; 20} 21PHP; 22 23echo ast_dump(ast\parse_code($code, $version=50)), "\n"; 24 25?> 26--EXPECTF-- 27AST_STMT_LIST 28 0: AST_CLASS 29 flags: 0 30 name: "A" 31 docComment: null 32 extends: null 33 implements: null 34 stmts: AST_STMT_LIST 35 0: AST_PROP_DECL 36 flags: MODIFIER_PUBLIC (%d) 37 0: AST_PROP_ELEM 38 name: "a" 39 default: null 40 docComment: "/** docComment $a */" 41 1: AST_PROP_DECL 42 flags: MODIFIER_PUBLIC (%d) 43 0: AST_PROP_ELEM 44 name: "b" 45 default: null 46 docComment: "/** docComment $b */" 47 1: AST_PROP_ELEM 48 name: "c" 49 default: null 50 docComment: "/** docComment $c */" 51 __declId: 0 52