The סעודה I was partaking in on Purim day continued well into the evening of the next day (Shushan Purim here in the US). Teffilah with a minyan was only available immediately after צאת הכוכבים, so a number of us decided to say ברכת המזון - with על הנסים - and then pray ערבית (without על הנסים). However, we were left wondering: would it have been permissible to say ערבית without על הנסים, continue the meal and then say ברכת המזון with על הנסים? Or, would this be considered תרי דסתרי - since saying ערבית without על הנסים would seem to declare that Purim is over and would preclude going back and saying על הנסים afterwards.
During some initial discussion it was suggested that this case is different from a situation where Shabbat falls out on Erev Rosh Hodesh, since saying both רצה and יעלה ויבוא during ברכת המזון after having eaten on both Shabbat and Rosh Hodesh in the same meal is not self contradictory in the same manner.
Can anyone point to sources of the הלכה for the scenario I have described?