Court ruling challenges residents' identity as students