for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Triadev\Leopard\Model;
class Location
{
/** @var float */
private $latitude;
private $longitude;
/**
* Location constructor.
* @param float $latitude
* @param float $longitude
*/
public function __construct(float $latitude, float $longitude)
$this->latitude = $latitude;
This check looks for multiple assignments in successive lines of code. It will report an issue if the operators are not in a straight line.
To visualize
$a = "a"; $ab = "ab"; $abc = "abc";
will produce issues in the first and second line, while this second example
will produce no issues.
$this->longitude = $longitude;
}
* @return float
public function getLatitude(): float
return $this->latitude;
public function getLongitude(): float
return $this->longitude;
This check marks files that end in a newline character, i.e. an empy line.