mirror of
https://github.com/php/php-src.git
synced 2024-12-01 05:43:38 +08:00
42 lines
380 B
PHP
42 lines
380 B
PHP
--TEST--
|
|
Testing nowdocs with escape sequences
|
|
--FILE--
|
|
<?php
|
|
|
|
$test = <<<'TEST'
|
|
TEST;
|
|
|
|
var_dump(strlen($test));
|
|
|
|
$test = <<<'TEST'
|
|
\
|
|
TEST;
|
|
|
|
var_dump(strlen($test));
|
|
|
|
$test = <<<'TEST'
|
|
\0
|
|
TEST;
|
|
|
|
var_dump(strlen($test));
|
|
|
|
$test = <<<'TEST'
|
|
\n
|
|
TEST;
|
|
|
|
var_dump(strlen($test));
|
|
|
|
$test = <<<'TEST'
|
|
\\'
|
|
TEST;
|
|
|
|
var_dump(strlen($test));
|
|
|
|
?>
|
|
--EXPECT--
|
|
int(0)
|
|
int(1)
|
|
int(2)
|
|
int(2)
|
|
int(3)
|