Generalized spin structures in quantum gravity