note 126785 added to function.gettype

From: Date: Thu, 20 Jan 2022 18:59:34 +0000
Subject: note 126785 added to function.gettype
Groups: php.notes 
Request: Send a blank email to php-notes+get-217525@lists.php.net to get a copy of this message
Same as for "boolean" below, happens with integers. gettype() return "integer" yet proper type hint is "int". If your project is PHP8+ then you should consider using get_debug_type() instead which seems to return proper types that match used for type hints. ---- Server IP: 45.112.84.4 Probable Submitter: 80.90.5.135 (proxied: 37.47.161.75) ---- Manual Page -- https://php.net/manual/en/function.gettype.php Edit -- https://main.php.net/note/edit/126785 Del: integrated -- https://main.php.net/note/delete/126785/integrated Del: useless -- https://main.php.net/note/delete/126785/useless Del: bad code -- https://main.php.net/note/delete/126785/bad+code Del: spam -- https://main.php.net/note/delete/126785/spam Del: non-english -- https://main.php.net/note/delete/126785/non-english Del: in docs -- https://main.php.net/note/delete/126785/in+docs Del: other reasons-- https://main.php.net/note/delete/126785 Reject -- https://main.php.net/note/reject/126785 Search -- https://main.php.net/manage/user-notes.php

« previous php.notes (#217525) next »