mirror of
https://github.com/smarty-php/smarty.git
synced 2025-07-31 08:27:14 +02:00
Brought lexer source functionally up-to-date with compiled version
Fixes #621
This commit is contained in:
@ -14,6 +14,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
- PHP5.3 compatibility fixes
|
- PHP5.3 compatibility fixes
|
||||||
|
- Brought lexer source functionally up-to-date with compiled version
|
||||||
|
|
||||||
## [3.1.36] - 2020-04-14
|
## [3.1.36] - 2020-04-14
|
||||||
|
|
||||||
|
@ -249,7 +249,13 @@ template ::= template PHP(B). {
|
|||||||
|
|
||||||
// template text
|
// template text
|
||||||
template ::= template TEXT(B). {
|
template ::= template TEXT(B). {
|
||||||
$this->current_buffer->append_subtree($this, $this->compiler->processText(B));
|
$text = $this->yystack[ $this->yyidx + 0 ]->minor;
|
||||||
|
|
||||||
|
if ((string)$text == '') {
|
||||||
|
$this->current_buffer->append_subtree($this, null);
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->current_buffer->append_subtree($this, new Smarty_Internal_ParseTree_Text($text, $this->strip));
|
||||||
}
|
}
|
||||||
// strip on
|
// strip on
|
||||||
template ::= template STRIPON. {
|
template ::= template STRIPON. {
|
||||||
@ -308,7 +314,7 @@ smartytag(A)::= SIMPLETAG(B). {
|
|||||||
$tag = trim(substr(B, $this->compiler->getLdelLength(), -$this->compiler->getRdelLength()));
|
$tag = trim(substr(B, $this->compiler->getLdelLength(), -$this->compiler->getRdelLength()));
|
||||||
if ($tag == 'strip') {
|
if ($tag == 'strip') {
|
||||||
$this->strip = true;
|
$this->strip = true;
|
||||||
A = null;;
|
A = null;
|
||||||
} else {
|
} else {
|
||||||
if (defined($tag)) {
|
if (defined($tag)) {
|
||||||
if ($this->security) {
|
if ($this->security) {
|
||||||
|
Reference in New Issue
Block a user