Skip to content

Conversation

@dependabot
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Nov 1, 2025

Bumps phan/phan from 5.5.1 to 5.5.2.

Release notes

Sourced from phan/phan's releases.

5.5.2

October 4 2025, Phan 5.5.2

New features:

  • Add some PHP 8.5 compatibility support - full support will be in Phan 6.x

Bug fixes:

  • Fix never-return type narrowing #5078
  • Fix issue #5063: Handle edge cases in type analysis
  • Fix issue #5074: Type inference improvements
  • Handle intersection types in @throws annotations #5073
  • Fix SelfType instantiation for class constants #5057
  • Map overridden method types before inheriting them #5068
  • Resolve static before emitting PhanTypeMismatchReturn #5067
  • Complain about ArrayObject/ArrayIterator with objects #5064
  • Allow @extends/@inherits in PHPDoc on traits again #5061
  • Normalize generic multi-type elements before expanding them #5059
  • Use mixed instead of empty union to substitute unspecified template types #5058
  • Flag 'catch' variables declared as unused in PHP 8 #5050
  • Fixed -l handling to support one or multiple files #5056
  • Add hash options argument to the 8.1 function signature delta map #5048
  • Increase max recursion depth in asExpandedTypes #5046
  • Infer more partial types for array union #5047
  • Restore compatibility with older php-ast #5045
  • Consider ClosureType as callable in CallableParamPlugin #5041
  • Move code for complex callables from ContextNode to UnionTypeVisitor #5039
  • Respect log_error for invalid maybe-callable FQSENs #5038
  • Emit issues for duplicate @template annotations #5082

Plugins:

  • UseReturnValuePlugin: support #[\NoDiscard] attribute #5051

Maintenance:

  • Update php-ast to 1.1.3 #5042
Changelog

Sourced from phan/phan's changelog.

Oct 4 2025, Phan 5.5.2

New features(Analysis):

  • Detect duplicate @template annotations #5082
    • New issue type: PhanTemplateTypeDuplicate - when the same @template type appears more than once in one comment
    • New issue type: PhanTemplateTypeShadowsClass - when the same @template type appears in a class comment and a (non-static) method comment
  • Handle intersection types in @throws annotations #5073, #5071
  • Flag catch variables declared as unused in PHP 8 #5050

New features(Plugins):

  • UseReturnValuePlugin: support #[\NoDiscard] attribute #5051
    • Detects when return values of functions/methods with #[\NoDiscard] attribute are ignored
    • Works even when the attribute class does not exist (PHP < 8.5)

Bug fixes:

  • Fix never-return type narrowing #5078
  • Fix SelfType instantiation in certain contexts #5069, #5057
  • Fix method type inheritance with generic concrete subclass overrides #5068, #4843
    • Map overridden method types before inheriting them
  • Fix static return type resolution in traits #5067, #4845
    • Resolve static before emitting PhanTypeMismatchReturn
  • Fix handling of @extends/@inherits in PHPDoc on traits #5061, #5002
    • Allow @extends/@inherits on traits to document that the trait is only used on specific classes
  • Fix ArrayObject/ArrayIterator type checking with object type parameters #5064
    • Now complains about ArrayObject/ArrayIterator with objects as type parameters
  • Normalize generic multi-type elements before expanding them #5059, #5049
    • (A|null)[] and (?A)[] are now treated consistently
  • Use mixed instead of empty union to substitute unspecified template types #5058, #5052
    • Better handling of template types used in union types (e.g., T|null becomes mixed|null instead of just null)
  • Fix phan_client -l flag handling to support one or multiple files #5056
  • Fix type inference for array unions #5047
    • Infer more partial types for array union
  • Increase max recursion depth in asExpandedTypes #5046
    • Fixes issues with long inheritance chains
  • Restore compatibility with older php-ast versions #5045
  • Consider ClosureType as callable in CallableParamPlugin #5041
  • Improve handling of complex callables #5039
    • Move code for complex callables from ContextNode to UnionTypeVisitor
  • Respect log_error for invalid maybe-callable FQSENs #5038

Miscellaneous:

  • Add hash options argument to the 8.1 function signature delta map #5048
  • Update php-ast to 1.1.3 #5042
  • Add PHP 8.5 compatibility fixes
    • Fix SplObjectStorage deprecations (replaced attach() with offsetSet(), contains() with offsetExists())
    • Add __unserialize() method to Type class to address PHP 8.5 deprecation
    • Suppress PHP 8.5 deprecation warnings in error handler for symfony/string compatibility
Commits
  • 25d7e8d 5.5.2 release
  • 98df848 Fix IntersectionTypeTest for __unserialize method
  • 019cb86 Add PHP 8.5 compatibility fixes for Phan v5
  • f15f08b Suppress PHP 8.5 deprecation warnings in error handler
  • b276a49 Merge pull request #5082 from MatmaRex/template-type-duplicate
  • e760018 Emit issues for duplicate @template annotations
  • a8d8488 Merge pull request #5078 from phan/never-return-type-narrowing-fix
  • a3a5c53 Add test
  • 95b9378 Fix never-return type narrowing
  • 4e54962 Merge pull request #5076 from phan/fix-5063
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.

Dependabot will merge this PR once CI passes on it, as requested by @nextcloud-command.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [phan/phan](https://github.com/phan/phan) from 5.5.1 to 5.5.2.
- [Release notes](https://github.com/phan/phan/releases)
- [Changelog](https://github.com/phan/phan/blob/v6/NEWS.md)
- [Commits](phan/phan@5.5.1...5.5.2)

---
updated-dependencies:
- dependency-name: phan/phan
  dependency-version: 5.5.2
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot added dependencies Pull requests that update a dependency file php Pull requests that update Php code labels Nov 1, 2025
@dependabot dependabot bot added dependencies Pull requests that update a dependency file php Pull requests that update Php code labels Nov 1, 2025
Copy link
Contributor

@nextcloud-command nextcloud-command left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dependabot merge

@dependabot @github
Copy link
Contributor Author

dependabot bot commented on behalf of github Nov 1, 2025

Beginning January 27, 2026, Dependabot will no longer support the @dependabot merge command. Please use GitHub's native pull request controls instead. Please see the changelog announcement for additional details.

@dependabot @github
Copy link
Contributor Author

dependabot bot commented on behalf of github Nov 1, 2025

One of your CI runs failed on this pull request, so Dependabot won't merge it.

Dependabot will still automatically merge this pull request if you amend it and your tests pass.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file php Pull requests that update Php code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants