RE: [PHP] Disturbing parsing problems

From: Date: Mon, 29 Jul 2002 16:41:58 +0000
Subject: RE: [PHP] Disturbing parsing problems
Groups: php.general 
Request: Send a blank email to php-general+get-110211@lists.php.net to get a copy of this message
Personally, I *love* one-line if statements :D However, I took your advice and used braces for all of them; same problem. I have parentheses with all of my if's, before the braces - I just forgot to include a few here. I haven't checked every () and [], but every {} is accounted for. The reason I refer to this problem as 'disturbing' is the fact that there are not equal numbers of open and close braces in *working* code. Regardless of other delimiters, that shouldn't be, right? >I don't like one line if statements. Perhaps there's a problem in there. >Makes things harder to see. I'd write it: > > while () {} > if () { > } elseif () { > }else { > } > >Does your code have the () between the if and {? > } > // } > if () { > if { > >Also, your problem could be arising because of some unnoticed (, ), { or } >in a command between your control statements. --Dan

« previous php.general (#110211) next »