fixing bugs.
fixed matching tokens above then below.