ConstructorDestructorReturnSniff
in package
implements
Sniff
FinalYes
Verify that a class constructor/destructor does not return anything, nor has a return type declaration (fatal error).
Tags
Table of Contents
Interfaces
Properties
- $phpVersion : int
- PHP version as configured or 0 if unknown.
Methods
- process() : void
- Processes this test, when one of its tokens is encountered.
- register() : array<string|int, int|string>
- Registers the tokens that this sniff wants to listen for.
Properties
$phpVersion
PHP version as configured or 0 if unknown.
private
int
$phpVersion
Tags
Methods
process()
Processes this test, when one of its tokens is encountered.
public
process(File $phpcsFile, int $stackPtr) : void
Parameters
- $phpcsFile : File
-
The file being scanned.
- $stackPtr : int
-
The position of the current token in the stack passed in $tokens.
Tags
register()
Registers the tokens that this sniff wants to listen for.
public
register() : array<string|int, int|string>