fixing not operator to keep boolean types normalized.