Interestingly, early high-level programming languages separated the keyword and identifier namespaces by using e.g. bold or underline for keywords. This way the parser did not get a heart attack if you named your variable "if". (Some later languages dropped the inconvenience of special character attributes and made the keywords all-uppercase. And later still there was C.)
So, another way to fix the '<' ambiguity would be to make the template-initiating angle bracket bold ;)