No, analog needs turning off, user ram starts at a different location, probably SFRs are in different banks, probably the config will be wrong. There's probably a few other things.
They both use the same functions and such, so you could port it pretty easily.
The problems you would run into, is if your first chip has SPI and the second didnt.
But in this case, standard code (nothing extravagant) should port just fine (As long as you watch register location)