From 2b50e1778b164e641c03c2e77176b6f47ca1e278 Mon Sep 17 00:00:00 2001 From: nsfisis Date: Sat, 18 Mar 2023 15:47:05 +0900 Subject: refactor: add RawHTML type to represent text node not being escaped --- .../write-fizzbuzz-in-php-2-letters-per-line/index.html | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'public/posts/2022-09-29/write-fizzbuzz-in-php-2-letters-per-line') diff --git a/public/posts/2022-09-29/write-fizzbuzz-in-php-2-letters-per-line/index.html b/public/posts/2022-09-29/write-fizzbuzz-in-php-2-letters-per-line/index.html index 93a0a0c..8d821d7 100644 --- a/public/posts/2022-09-29/write-fizzbuzz-in-php-2-letters-per-line/index.html +++ b/public/posts/2022-09-29/write-fizzbuzz-in-php-2-letters-per-line/index.html @@ -689,15 +689,15 @@ ${ 先程と同じく、chrprintfを生成する部分は長くなるので省いた。

-
${
-'_
-'}
+
${
+'_
+'}

は変数で、中にはスペースとエスケープが入っている (chr(32) . chr(92))。シェルに渡されている文字列は次のようになる。

-
e\
+            
e\
 c\
 h\
 o\
@@ -718,9 +718,9 @@ o\
               ちなみに、PHP 8.2 からは、この記法で Warning が出るようになるようだ。
             

-
${
-'_
-'}
+
${
+'_
+'}

最新版で警告が出るというのも美しくないので、私としては本編の解法を推す。 -- cgit v1.2.3-70-g09d2