same string cast for template references