tightened up the symbol branching logic