In what setting are you mixing LaTeX and C code?

Pretty common to emit latex from C, no?

No, no, TeX macros nested within other TeX macros.