When you declare more than one variable on the same line they need to be seperated by a comma.

var %chan = #channel, %a = $nick(%chan,0)