#45926 [Bgs]: Improper code interpretation without compound statement

From: Date: Tue, 26 Aug 2008 22:42:39 +0000
Subject: #45926 [Bgs]: Improper code interpretation without compound statement
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-128444@lists.php.net to get a copy of this message
ID: 45926 User updated by: atomo64 at gmail dot com Reported By: atomo64 at gmail dot com Status: Bogus Bug Type: Scripting Engine problem Operating System: linux 2.6 PHP Version: 5.2.6 New Comment: This bug was submitted at Debian and after re-checking the manual I found no defined behaviour. But if ?>oops, something here<?php is not interpreted as an statement then the following script should not print "foo\n": <?php if (false) { ?>nothing here<?php } if (false) ?>oops, something here<?php echo "foo\n"; ?> I believe there's a bug here, either in the interpreter or in the documentation. Previous Comments: ------------------------------------------------------------------------ [2008-08-26 22:15:39] jani@php.net Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.php.net/manual/ and the instructions on how to report a bug at http://bugs.php.net/how-to-report.php ------------------------------------------------------------------------ [2008-08-26 17:05:54] atomo64 at gmail dot com Description: ------------ Conditional statements resulting into non-php code (?> foo <?php) without compound statements are not properly interpreted. Reproduce code: --------------- <?php if (false) { ?>nothing here<?php } if (false) ?>oops, something here<?php ?> Expected result: ---------------- (no output) Actual result: -------------- oops, something here ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=45926&edit=1

« previous php.bugs (#128444) next »