note 103395 added to control-structures.switch

From: Date: Tue, 12 Apr 2011 04:48:46 +0000
Subject: note 103395 added to control-structures.switch
Groups: php.notes 
Request: Send a blank email to php-notes+get-178717@lists.php.net to get a copy of this message
@hamiltont at gmail dot com: That will always result in a 2 - because default is always executed in a switch statement unless the parser reaches a break before a default. Your logic is fallible. ---- Server IP: 69.147.83.197 Probable Submitter: 203.206.238.245 ---- Manual Page -- http://www.php.net/manual/en/control-structures.switch.php Edit -- https://master.php.net/note/edit/103395 Del: integrated -- https://master.php.net/note/delete/103395/integrated Del: useless -- https://master.php.net/note/delete/103395/useless Del: bad code -- https://master.php.net/note/delete/103395/bad+code Del: spam -- https://master.php.net/note/delete/103395/spam Del: non-english -- https://master.php.net/note/delete/103395/non-english Del: in docs -- https://master.php.net/note/delete/103395/in+docs Del: other reasons-- https://master.php.net/note/delete/103395 Reject -- https://master.php.net/note/reject/103395 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#178717) next »