[OT] C# can do all the interpolated strings now

Ola Fosheim Grøstad ola.fosheim.grostad at gmail.com
Thu Dec 9 14:30:33 UTC 2021

On Thursday, 9 December 2021 at 14:13:58 UTC, Ola Fosheim Grøstad 
> On Thursday, 9 December 2021 at 14:04:18 UTC, Kagamin wrote:
>> DSLs are already possible with template mixins in a clean form 
>> without sigils.
> You mean as string mixins?

Just to clarify to avoid unnecessary discussion about what I 
wrote, as I might not have been specific enough:

I am not suggesting the implementation of builtin string 
interpolation, but custom literals with conversion functions. It 
should probably not be called ```string_interpolation```, just 
```convert``` or ```@convert```.

This is different from string mixins as it would be more 
composable, overloadable, and with stronger typing and no 

It should work for custom literals like ```100.34ms``` as well as 
```sql"SELECT …"```.

As such, you would integrate the "DSL" more with regular D-code 
than you do with string mixins.

Basically: try to find a generic solution for custom literals 
that allows the implementation of string-interpolation.

More information about the Digitalmars-d mailing list