Detect cases such as var(), var(-), var("a") or var(21) early and report them as syntax errors. Test included. Related: #6715