Formalizing f-strings
Formalizing f-strings
Posted Jan 18, 2023 9:20 UTC (Wed) by anselm (subscriber, #2796)In reply to: Formalizing f-strings by nbecker
Parent article: Formalizing f-strings
If you don't mind the extra braces, then fr'$x^2+\sigma^{{{coef}}}$' should work. (Note how you can combine f'…' and r'…', so fr'\alpha' will do the Right Thing even if '\a' would otherwise come out as '\x07'.)
Tedious, perhaps, but not impossible.