Re: Re: [RFC] Better string interpolation
| From: | Ilija Tovilo | Date: | Mon, 17 Aug 2020 18:01:25 +0000 |
| Subject: | Re: Re: [RFC] Better string interpolation | ||
| References: | 1 2 3 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-111595@lists.php.net to get a copy of this message | ||
Hi Alex
>> I've been thinking about ways to improve string interpolation.
>
> Using a prefix for strings that have a saner interpretation reminds me of f-strings in python
> 3. I would suppose you know about it already but I'll leave a link here anyway:
> https://www.python.org/dev/peps/pep-0498/
>
> Maybe f can be used similar with how it is in python but I didn't gave too much thought
> into it. I'm a casual python user so I need to understand more the history how they got to it.
According to the RFC the f stands for formatted string. The $ I chose
comes from C#. I don't feel strongly about either option, I think
since IDEs will help with syntax highlighting it probably doesn't
matter too much. I might look into other languages and create a short
overview/comparison.
Ilija