菜谱项目

groupUseTrailingComma.test 940B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. Group use can have trailing comma
  2. -----
  3. <?php
  4. use A\{B,};
  5. use function A\{b,};
  6. -----
  7. !!php7
  8. array(
  9. 0: Stmt_GroupUse(
  10. type: TYPE_UNKNOWN (0)
  11. prefix: Name(
  12. parts: array(
  13. 0: A
  14. )
  15. )
  16. uses: array(
  17. 0: Stmt_UseUse(
  18. type: TYPE_NORMAL (1)
  19. name: Name(
  20. parts: array(
  21. 0: B
  22. )
  23. )
  24. alias: B
  25. )
  26. )
  27. )
  28. 1: Stmt_GroupUse(
  29. type: TYPE_FUNCTION (2)
  30. prefix: Name(
  31. parts: array(
  32. 0: A
  33. )
  34. )
  35. uses: array(
  36. 0: Stmt_UseUse(
  37. type: TYPE_UNKNOWN (0)
  38. name: Name(
  39. parts: array(
  40. 0: b
  41. )
  42. )
  43. alias: b
  44. )
  45. )
  46. )
  47. )