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

deadalnix deadalnix at gmail.com
Thu Dec 9 16:24:12 UTC 2021


On Thursday, 9 December 2021 at 14:25:58 UTC, WebFreak001 wrote:
>> But don't you think it would be better if you could write:
>>
>> ```
>> sql"SELECT x,y,z FROM {something} FROM {condition}"
>> ```
>>
>> [...]
>
> Love the idea of having type-safety with this! JS has similar 
> syntax with `` sql`...` `` where it will call the function 
> `sql` with the parts of the interpolated string.
>
> https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals

This approach has proven extremely useful in many contexts. I'm 
not sure why this is frowned upon.


More information about the Digitalmars-d mailing list