revising desugaring of `and` and `or` so that they check types, and
adding tests to ensure that they do