The Wilmot Proviso, which stated that slavery would not be permitted in any territory gained from Mexico,