Julia uses $foo for both string interpolation and backquoting in macros. That's *really* nice.
miniblog.
Related Posts
One underrated perk of string interpolation: it arguably simplifies type checking.
If you have a format() function you need to support variadic functions and even format specifiers in the type system.
Syntactic diffing with interpolation is an interesting problem.
Same: 1 + 2 vs 1+2
Different: "1 + 2" vs "1+2"
Same: "#{1 + 2}" vs "#{1+2}"
Difftastic is smart enough to get the first two cases correct, but still considers the third case to be different strings.
One striking downside of string interpolation is that accurate syntax highlighting becomes much harder.
It's very easy to add some form of nesting, which breaks the "simple lexer" approach to highlighting.