Fix the logic in ExprSMTLIBPrinter::getSort

This now corresponds to the sorts of the operations we emit, as far as I
can tell.