eclipse-pdt / pdt

PHP Development Tools project (PDT)
https://eclipse.org/pdt
Eclipse Public License 2.0
188 stars 46 forks source link

not detecting method implemented in parent class #255

Closed aln-1 closed 9 months ago

aln-1 commented 9 months ago

php 8.2

interface SomeInterface { abstract public function someFunction (); }

abstract class Parent implements SomeInterface { public function someFunction () { } }

class Child extends Parent { }

Eclipse will flag the "Child" class with errors and will recommend to implement the "someFunction" method or to make the class abstract. Which is of course wrong.

pounard commented 9 months ago

It happens sometime when code isn't inside the build path / include path.

zulus commented 9 months ago

Strange. Which PDT version you use? On recent snapshot I see only error for "Parent" keyword, could be also for "abstract" but this is another case

aln-1 commented 9 months ago

yes, wrong choice of names in my example . of course "parent" is a reserved word. I'm using pdt plugin version 8.0.0.202306041617. My real life example is a laravel Model implementation. Eclipse complains that the "ArrayAccess" methods are not implemented but in fact they are implemented in the laravel model base class.

aln-1 commented 9 months ago
Screenshot 2023-10-11 at 14 47 59
zulus commented 9 months ago

Latest stable is 8.1, current snapshot 8.2, I cannot reproduce here

aln-1 commented 9 months ago

it is indeed solved with 8.1