Skip to content

PHP 8 Future Improvements #19

@rotexdegba

Description

@rotexdegba
  • Improve type hints by using Union Types or mixed where appropriate in the code base.
    • Run ./vendor/bin/psalm --show-info=true to get suggestions for where more type-hints are needed
  • Rather than returning instances of CollectionInterface in methods in \VersatileCollections\CollectionInterface try returning static
  • Try to see if constructors can be refactored so that we can do stuff like __construct(mixed ...$items) in GenericCollection & __construct(int ...$items) in IntsCollection, etc. If it works, we can get rid of the check type code in specialized collections

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions