Rather than doing this, you can use MCStringFormat() to create a (printf-style) formatted StringRef.