Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.12.26 - issue with trait using another trait #3415

Closed
dmaicher opened this issue Jun 8, 2020 · 7 comments
Closed

0.12.26 - issue with trait using another trait #3415

dmaicher opened this issue Jun 8, 2020 · 7 comments

Comments

@dmaicher
Copy link

dmaicher commented Jun 8, 2020

Bug report

With the latest 0.12.26 release I got some error on a trait using another trait 馃構

Code snippet that reproduces the problem

<?php declare(strict_types = 1);

trait FooParentTrait {
    public function bar() {
        echo "bar";
    }
}

trait Foo {
    use FooParentTrait;
}

class SomeClass {
    use Foo {
        bar as baz;
    }

    public function __construct()
    {
        $this->baz();
    }
}

new SomeClass();

See https://phpstan.org/r/52adcded-4689-4d96-ab9e-c277a54d9f6d

Expected output

No error should be reported there.

@dmaicher dmaicher changed the title 0.12.26 0.12.26 - issue with trait using another trait Jun 8, 2020
@VincentLanglet
Copy link
Contributor

You can even get an internal error this way
https://phpstan.org/r/c4724ea6-b7d5-49a0-81b9-89869eb27467

@loevgaard
Copy link

This is still an issue in phpstan 0.12.27

@ondrejmirtes
Copy link
Member

Waiting for Roave/BetterReflection#659 to be fixed.

@ondrejmirtes
Copy link
Member

Fixed: ondrejmirtes/BetterReflection@f7cb790 + phpstan/phpstan-src@e36d163, original credit goes to @kukulich in Roave/BetterReflection#652.

@dktapps
Copy link
Contributor

dktapps commented Jun 14, 2020

Great, is there any ETA for a release?

@ondrejmirtes
Copy link
Member

Most likely today

@github-actions
Copy link

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 17, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants