Skip to content
This repository was archived by the owner on Apr 3, 2020. It is now read-only.
This repository was archived by the owner on Apr 3, 2020. It is now read-only.

Type Hinting #284

@Azareal

Description

@Azareal

Type Hinting was one of the big features which landed in PHP7, I'm assuming you already have an idea as to what it is, but in short you can mark methods, functions, etc. up with little type hints as to what it will expect and the language will scream when you violate those constraints.

It should help to find cases where strange inputs are passed to a method / function, usually the sign of a bug. And it helps methods / functions to be self-documenting. I briefly mentioned it on Discord to @euantorano and he seemed supportive of the idea.

I'm working on a pull request for this. Type hinting is actually already used in MyBB2, albeit rarely.
My upcoming pull request will help to greatly expand the coverage. #286

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