Abbreviation And Hungarian (ARCH7011)
هذا المحتوى غير متوفر بلغتك بعد.
Key php.naming.no-hungarian-notation · Severity info · Category naming
Hungarian-notation type prefixes such as strName, iCount, b_flag and cryptic abbreviations add noise the type system already provides. Identifiers should describe purpose, not type.
Incorrect
Section titled “Incorrect”<?php
class Report{ public function build(string $strTitle, int $iCount): void { $b_done = false; }}Correct
Section titled “Correct”<?php
class Report{ public function build(string $title, int $count): void { $done = false; }}Drop the type prefix and cryptic abbreviations; use clear, purpose-describing names.