Typo¶
A typo is short for “typographical error”. It refers to a mistake made in the typing of the code. Typographical errors can include misspelled words, misplaced opertors. Typos can occur in various contexts, such as types, expressions, naming.
A typo can lead to a visible or invisible error.
Typo happen in any text based system.
<?php
// The typo has placed the === false INSIDE the in_array(), and changes the behavior
if (in_array($array, $value, $strict === false)) {
}
// the type and is not expected, instead of an integer
function foo(ant $i) {
}
?>