Perl recognises that it is a bad practice.
perl -we ' print "true\n" if "12" == "12php"'
Argument "12php" isn't numeric in numeric eq (==) at -e line 1.
true
perl -w -e 'my $foo = "12php"; $foo = $foo + 1; print $foo, "\n";'
Argument "12php" isn't numeric in addition (+) at -e line 1.
13
(an exception seems to be made for $foo++ though... that's Perl for you).