Showing 839 of 839 total issues
The property $is_generic is not named in camelCase. Open
class NameTypeParselet implements PrefixParselet
{
private $is_generic;
public function __construct($is_generic = false)
- Read upRead up
- Exclude checks
CamelCasePropertyName
Since: 0.2
It is considered best practice to use the camelCase notation to name attributes.
Example
class ClassName {
protected $property_name;
}
Source
The property $scope_level is not named in camelCase. Open
abstract class Parser
{
use Parselet;
public $input;
- Read upRead up
- Exclude checks
CamelCasePropertyName
Since: 0.2
It is considered best practice to use the camelCase notation to name attributes.
Example
class ClassName {
protected $property_name;
}
Source
The parameter $parent_scope is not named in camelCase. Open
abstract public function injectScope($parent_scope);
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $parent_scope is not named in camelCase. Open
public function injectScope($parent_scope)
{
$this->scope = new Scope($parent_scope);
foreach ($this->parameters as $param) {
if ($this->scope->hasLocal($param->name)) {
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $parent_scope is not named in camelCase. Open
public function injectScope($parent_scope)
{
$this->scope = $parent_scope;
}
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $parent_scope is not named in camelCase. Open
public function injectScope($parent_scope)
{
$this->scope = $parent_scope;
$this->condition->injectScope($parent_scope);
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The property $is_generic is not named in camelCase. Open
class NameType extends TypeNode
{
use NameTypeChecker;
use NameTypeRenderer;
- Read upRead up
- Exclude checks
CamelCasePropertyName
Since: 0.2
It is considered best practice to use the camelCase notation to name attributes.
Example
class ClassName {
protected $property_name;
}
Source
Avoid variables with short names like $n. Configured minimum length is 3. Open
public function forwardCursor($n)
- Read upRead up
- Exclude checks
ShortVariable
Since: 0.2
Detects when a field, local, or parameter has a very short name.
Example
class Something {
private $q = 15; // VIOLATION - Field
public static function main( array $as ) { // VIOLATION - Formal
$r = 20 + $this->q; // VIOLATION - Local
for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
$r += $this->q;
}
}
}
Source https://phpmd.org/rules/naming.html#shortvariable
The parameter $parent_scope is not named in camelCase. Open
public function injectScope($parent_scope)
{
$this->left->injectScope($parent_scope);
$this->index->injectScope($parent_scope);
}
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $parent_scope is not named in camelCase. Open
public function injectScope($parent_scope)
{
$this->scope = new Scope($parent_scope);
// Bind where-symbols
foreach ($this->clauses as $clause) {
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $stmt_list is not named in camelCase. Open
public function __construct($stmt_list)
{
$this->stmt_list = $stmt_list;
}
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $parent_scope is not named in camelCase. Open
public function injectScope($parent_scope)
{
$this->scope = $parent_scope;
$symbol = $parent_scope->lookup($this->name);
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $parent_scope is not named in camelCase. Open
public function injectScope($parent_scope)
{
$defined = [];
$operators = [];
$index = 0;
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $parent_scope is not named in camelCase. Open
public function injectScope($parent_scope)
{
$this->right->injectScope($parent_scope);
}
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $parent_scope is not named in camelCase. Open
public function injectScope($parent_scope)
{
$this->scope = $parent_scope;
$this->from->injectScope($parent_scope);
$this->to->injectScope($parent_scope);
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $parent_scope is not named in camelCase. Open
public function injectScope($parent_scope)
{
$this->scope = new Scope($parent_scope);
return $this->body->injectScope($this->scope);
}
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $parent_scope is not named in camelCase. Open
public function injectScope($parent_scope)
{
$parent_scope->insert($this->signature->name, Symbol::S_VARIABLE);
$this->scope = new Scope($parent_scope);
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $has_brackets is not named in camelCase. Open
public function __construct($parameters, $kind, $body, $has_brackets)
{
$this->parameters = $parameters;
$this->kind = $kind;
$this->body = $body;
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
The parameter $parent_scope is not named in camelCase. Open
public function injectScope($parent_scope)
{
$this->scope = new Scope($parent_scope);
// Pre-inject label symbol
$this->scope->insert($this->name, Symbol::S_LABEL);
- Read upRead up
- Exclude checks
CamelCaseParameterName
Since: 0.2
It is considered best practice to use the camelCase notation to name parameters.
Example
class ClassName {
public function doSomething($user_name) {
}
}
Source
Avoid variables with short names like $me. Configured minimum length is 3. Open
$me = $this->types[$i];
- Read upRead up
- Exclude checks
ShortVariable
Since: 0.2
Detects when a field, local, or parameter has a very short name.
Example
class Something {
private $q = 15; // VIOLATION - Field
public static function main( array $as ) { // VIOLATION - Formal
$r = 20 + $this->q; // VIOLATION - Local
for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
$r += $this->q;
}
}
}