Skip to content

Inferred types should be backtracked up to method definition #9

@sk-

Description

@sk-

When inferring types within a function, those should be used to compute the type signature of the function. For example

<?php

function foo($foo) {
    return $foo + 2;
}

gives the error

Notice: Type mismatch: expected: Numeric, found: Any
return $foo + 2;

However, the type inferencer should detect that in this case foo receives a numeric argument and enforce it later.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions