Bug #53060 [Opn->Bgs]: End tag ; ignored on last statement
Edit report at http://bugs.php.net/bug.php?id=53060&edit=1
ID: 53060
Updated by: rasmus@php.net
Reported by: musicdev at gmail dot com
Summary: End tag ; ignored on last statement
-Status: Open
+Status: Bogus
Type: Bug
Package: *General Issues
Operating System: Windows 7 Ultimate
PHP Version: 5.3.3
Block user comment: N
New Comment:
No, ; is the statement separator and it is perfectly consistent the way
it is
since you are not separating any statements there.
Previous Comments:
------------------------------------------------------------------------
[2010-10-14 04:15:04] musicdev at gmail dot com
Description:
------------
I'm not completely sure that this is an intended behavior. In a php
script, the last statement can be left unclosed (without the ";").
Please see below script. The behavior does not seem to be negative as
the last statement is reached, however, the expected result is
consistency and all statements need to be closed.
Test script:
---------------
<?php
echo "test"
?>
Expected result:
----------------
In the short script provided, I expect php to provide an error stating
that the statement is not closed using the closing semi-colon (;).
Actual result:
--------------
The actual result is that the script runs as normal and echos the "test"
statement, though the statement is not closed.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/bug.php?id=53060&edit=1
Thread (2 messages)