I don´t think there would be any probelms with that...with my experience at the mexican customs, they hardly even look at your passport/documents and just stamp it.
I actually went to migration a couple of weeks ago to ask about this, because my student visa is about to expire on august 6th...