Re: omitting T_CLOSE_TAG

From: Date: Mon, 29 Aug 2005 20:14:46 +0000
Subject: Re: omitting T_CLOSE_TAG
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-18534@lists.php.net to get a copy of this message
> I am searching for some evidence in the PHP source code that the > possibility of omitting the closing PHP tag is absolutely intentional, > and in fact part of the language syntax, and therefore it is going to be > supported indefinitely. Digging for T_CLOSE_TAG and similar stuff have > lead me to nothing. > I can't imagine a situation where that level of BC breakage would *EVER* be permitted. In fact, last I heard it was recommended practice for PEAR files to omit the end tag. I suppose it might accidently break if include were ever shifted to C style inclusion, but that breakage would wind up being considered a bug in the "new feature" and could be easily fixed by automatically reseting the lexer state before and after the include statement. > Actually I would like to clarify and possibly extend the note on page: > http://php.net/manual/en/basic-syntax.instruction-separation > An example might be helpful... "<?php echo 'Foo'; ?>" and "<?php echo 'Foo';" are interpreted identically by PHP. -Sara

« previous php.internals (#18534) next »