Review 10.4 Merged

75138[BUGFIX] Enhance annotation integrity test script

Stefan Bürk CR +2 V +2 Easy +18 −9 updated 07/13/22, 08:06

Commit message

Docblock annotations with more then one space between a wildcard
character `*` and the annotation start character `@` was not found.
Additionally, annotation identifiers did not regonize hyphens as
valid identifier character, thus cutting of e.g. phpstan annoations.

This patch now properly finds annotions with multi-space separations
and annotation identifiers containing hyphens. Additionally, two
phpstan specific annotations are allowed.

> https://phpstan.org/writing-php-code/phpdoc-types#local-type-aliases

Summarized contained tasks:

> find multi-space separated annotations
  e.g. `*  @<AnnotationIdentifier>`
> properly extract full annotation identifier containing hyphens
  e.g. `* @annoation-identifier-with-hyphen`
> add `@phpstan-type` and `@phpstan-import-type` as allowed
  annotation, but only on class level, and not on class-property
  or class-method level

Review

  • Code review CR +2 Done
    • Stefan Bürk +2
  • Verified V +2 Done
    • Stefan Bürk +2
    • core-ci +1 CI

Issues 3

Files 2

Review log 46

  1. Stefan Bürk commented on patch set 1 07/13/22, 07:01

    Cherry Picked from branch 11.5.
  2. core-ci voted on patch set 1 V -1 07/13/22, 07:09 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/29035

  3. Stefan Bürk uploaded patch set 2 07/13/22, 07:30

  4. core-ci voted on patch set 2 V +1 07/13/22, 07:37 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/29037

  5. Stefan Bürk voted on patch set 2 V +2 CR +2 07/13/22, 08:06

  6. Stefan Bürk merged patch set 3 07/13/22, 08:06