Skip to content

Wrong deprecation error from when parent::deprecatedMethod() called from trait #52

Open
@mvorisek

Description

@mvorisek

code https://github.com/atk4/data/blob/bb1c18f5dc583fca7dd372f98a0172fe66663057/src/Persistence/Sql/Postgresql/PlatformTrait.php#L115

ci https://github.com/atk4/data/runs/4342242942?check_suite_focus=true#step:11:16

 ------ ---------------------------------------------------------------------------------- 
  Line   src/Persistence/Sql/Postgresql/PlatformTrait.php (in context of anonymous class)  
 ------ ---------------------------------------------------------------------------------- 
  115    Call to method getCreateTableSQL() of deprecated class                            
         Doctrine\DBAL\Platforms\AbstractPlatform:                                         
         Use {@link PostgreSQLPlatform} instead.                                           
 ------ ---------------------------------------------------------------------------------- 

trait is implemented in anonymous class https://github.com/atk4/data/blob/bb1c18f5dc583fca7dd372f98a0172fe66663057/src/Persistence/Sql/Connection.php#L279

thus parent::getCreateTableSQL(... call inside the trait refers to (by the phpstan error recommended) PostgreSQLPlatform class

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