From 976ae3c51db42e0721bbbd0dd0ac50e30cca917c Mon Sep 17 00:00:00 2001
From: AlwaysVictorious <213483686+AlwaysVictorious@users.noreply.github.com>
Date: Fri, 14 Aug 2026 13:08:59 +0200
Subject: [PATCH 1/2] Clarify heredoc indentation in PHP example
Updated heredoc example to clarify indentation applies to the identifier and not the result
---
language/types/string.xml | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/language/types/string.xml b/language/types/string.xml
index 2013b079d4c5..bbed5e62fad2 100644
--- a/language/types/string.xml
+++ b/language/types/string.xml
@@ -233,7 +233,7 @@ echo 'Variables do not $expand $either', PHP_EOL;
Date: Fri, 14 Aug 2026 13:26:25 +0200
Subject: [PATCH 2/2] Update indentation rules and examples in string.xml
---
language/types/string.xml | 31 ++++++++++++++++---------------
1 file changed, 16 insertions(+), 15 deletions(-)
diff --git a/language/types/string.xml b/language/types/string.xml
index bbed5e62fad2..56296a24b68b 100644
--- a/language/types/string.xml
+++ b/language/types/string.xml
@@ -216,8 +216,9 @@ echo 'Variables do not $expand $either', PHP_EOL;
- The closing identifier may be indented by space or tab, in which case
- the indentation will be stripped from all lines in the doc string.
+ The closing identifier may be indented with spaces or tabs. Whitespace
+ equal to the closing identifier's indentation is then removed from the
+ beginning of every line in the doc string.
Prior to PHP 7.3.0, the closing identifier must
begin in the first column of the line.
@@ -240,13 +241,13 @@ echo <<
&example.outputs.73;
@@ -256,9 +257,9 @@ echo <<
@@ -308,23 +309,23 @@ Parse error: Invalid body indentation level (expecting an indentation level of a
// different indentation for body (spaces) and ending marker (tabs)
{
- echo <<