Skip to content

Latest commit

 

History

History
29 lines (22 loc) · 546 Bytes

final_static_access.rst

File metadata and controls

29 lines (22 loc) · 546 Bytes

Rule final_static_access

Warning

This rule is deprecated and will be removed on next major version.

You should use self_static_accessor instead.

Converts static access to self access in final classes.

Examples

Example #1

--- Original
+++ New
 <?php
 final class Sample
 {
     public function getFoo()
     {
-        return static::class;
+        return self::class;
     }
 }