Fork me on GitHub
a Sensio Labs Product

Oliva (v3.11.0) edition

Rule class_keyword_remove

Converts ::class keywords to FQCN strings.

Warning

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

Examples

Example #1

--- Original
+++ New
 <?php

 use Foo\Bar\Baz;

-$className = Baz::class;
+$className = 'Foo\Bar\Baz';
The logo is © 2010-2022 Sensio Labs