[fpc-devel] Current "state of opinion" on multiline strings? I still have this up-to-date locally with trunk FPC, despite having neglected pushing this anywhere online for a while now.

Marcos Douglas B. Santos md at delfire.net
Sun Dec 22 12:19:44 CET 2024


On Sun, Dec 22, 2024 at 7:15 AM Hairy Pixels via fpc-devel
<fpc-devel at lists.freepascal.org> wrote:
>
> On Dec 22, 2024 at 9:29:37 AM, Ben Grasset via fpc-devel <fpc-devel at lists.freepascal.org> wrote:
>>
>> I'd certainly don't really WANT to adapt to the (like I said, worse in my opinion) Delphi version, but I would if I "had" to. So that's why I figured I'd check in to see what people's general thoughts are on all of this nowadays.
>
>
>
> What is Delphi doing? This?
>
> var s: String = ‘’'
>                  hello world
>                         ‘’’;
>
> That or backticks are the only thing that made sense to me. What are the pros and cons of both? Backticks are easier to type maybe, but I kind of like the block effect the triple single-quotes make. Backticks are familiar from another popular language (JavaScript) so there’s that.
>

Delphi 12 uses 3 apostrophes to initialize/finish a string block.

best regards,
Marcos Douglas


More information about the fpc-devel mailing list