<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body dir="auto">
Technically there is no reason why we couldn’t. It would, however, be difficult to call the result a text ‘block’. Thick quotes?
<div><br>
</div>
<div>The answer is simply ‘reserved for future use’. The rationale is to provide the block structure that you’ve come to know and leave a space where we could in future we could put additional information describing the content. </div>
<div><br>
</div>
<div>Cheers,</div>
<div><br>
</div>
<div>— Jim </div>
<div>
<div><br>
</div>
<div><br>
<br>
<div dir="ltr">📱</div>
<div dir="ltr"><br>
<blockquote type="cite">On Nov 30, 2022, at 6:10 AM, Vikram Bakshi <vab2048@gmail.com> wrote:<br>
<br>
</blockquote>
</div>
<blockquote type="cite">
<div dir="ltr">
<div dir="ltr">
<div>Hi all,</div>
<div><br>
</div>
<div>Does anybody on the mailing list want to bite and answer the message I had sent earlier?</div>
<div><br>
</div>
<div>Even if it is to say "no we will not be doing that because <xyz>" - that would suffice!<br>
</div>
<div><br>
</div>
<div>Regards,</div>
<div>Vikram <br>
</div>
<div><br>
</div>
<br>
<div class="gmail_quote">
<div dir="ltr" class="gmail_attr">On Tue, Nov 22, 2022 at 10:42 AM Vikram Bakshi <<a href="mailto:vab2048@gmail.com">vab2048@gmail.com</a>> wrote:<br>
</div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div dir="ltr">
<div>Hello,</div>
<div><br>
</div>
<div>Text blocks are a great feature of the Java language. On the JEP page one of the listed goals of text blocks is to:</div>
<span style="color:rgb(0,0,255)"><i></i></span>
<div><span style="color:rgb(0,0,255)"><i></i></span><br>
<ul>
<li><span style="color:rgb(0,0,255)"><i>Enhance the readability of strings in Java programs that denote code written in non-Java languages.</i></span>
</li></ul>
</div>
<div><br>
</div>
<div>Currently when attempting to use text blocks for short strings which can fit on one line for a non-Java language (e.g. JSON) we still need to start the string on another line.</div>
<div><br>
</div>
<div>For example:</div>
<div><br>
</div>
<div>```java</div>
<div>var json = """</div>
<div> { "color": "red", "value": "#f00" } """<br>
</div>
<div>```<br>
</div>
<div><br>
</div>
<div>It would be a lot nicer to have the ability to use the triple quote to define strings like this on one line:</div>
<div><br>
</div>
<div>
<div>```java</div>
<div>var json = """{ "color": "red", "value": "#f00" } """<br>
</div>
<div>```</div>
<div><br>
</div>
<div>Currently that is not possible and using a normal quote for strings, ", requires us to escape all of the subsequent quotes on the same line - which is a real pain.</div>
<div><br>
</div>
<div>Obviously we can just continue to start on the next line to avoid the issue - but is it possible to consider an extension to text blocks which allow for this use case (short one line strings)?</div>
<div><br>
</div>
<div>Regards,</div>
<div>Vikram<br>
</div>
</div>
</div>
</blockquote>
</div>
</div>
</div>
</blockquote>
</div>
</div>
</body>
</html>