1--TEST-- 2PhpToken constructor 3--EXTENSIONS-- 4tokenizer 5--FILE-- 6<?php 7 8$token = new PhpToken(300, 'function'); 9var_dump($token); 10$token = new PhpToken(300, 'function', 10); 11var_dump($token); 12$token = new PhpToken(300, 'function', 10, 100); 13var_dump($token); 14 15?> 16--EXPECT-- 17object(PhpToken)#1 (4) { 18 ["id"]=> 19 int(300) 20 ["text"]=> 21 string(8) "function" 22 ["line"]=> 23 int(-1) 24 ["pos"]=> 25 int(-1) 26} 27object(PhpToken)#2 (4) { 28 ["id"]=> 29 int(300) 30 ["text"]=> 31 string(8) "function" 32 ["line"]=> 33 int(10) 34 ["pos"]=> 35 int(-1) 36} 37object(PhpToken)#1 (4) { 38 ["id"]=> 39 int(300) 40 ["text"]=> 41 string(8) "function" 42 ["line"]=> 43 int(10) 44 ["pos"]=> 45 int(100) 46} 47