Unitarity and modular invariance as constraints on four-dimensional superstrings