1
empty()falsy-nessテストとbool型キャストとの間に違いはありますか?空
は、次のような場合にfalsyネスを検出:
"" (an empty string)
0 (0 as an integer)
0.0 (0 as a float)
"0" (0 as a string)
NULL
FALSE
array() (an empty array)
$var; (a variable declared, but without a value)
はbool型キャストでFalseに変換され、その他の値はありますか?
質問は何ですか?理解できない –
PHP Docsのリストが間違っていると思いますか? –
あなたは本当に何を望んでいるのか、あなたの本当の質問は何ですか? –