Yemos HaMoshiach and Gedarim — Eruvin 43b

The Gemara tells us that although Eliyahu HaNavi does not come on Erev Shabbos, Moshiach may come on a Friday. The Gemara explains that Eliyahu does not come because his coming will disrupt preparations for Shabbos. Moshiach's advent, on the other hand, will not be as disruptive, since when he comes the non-Jews will serve the Jews, and prepare for Shabbos for them.

The obvious question is, what about the cooking for Shabbos. How can the non-Jews cook for the Jews for Shabbos in view of the prohibition on Bishul Akum? And, what about the preparation of wine for Shabbos, in view of the prohibition on Stam Yeinam?

The Meshech Chochmah (to Shemos12:22) notes that in Egypt, the Jews did not keep the mitzvos, but did keep the fences and barriers — they did not change their names, language and clothes. Conversely, in the Babylonian exile the Jews kept the Torah, but spoke the language of the land, changed their names, and married into the local populace.

Asserts the Meshech Chochmah, in Galus the fences and barriers are of primary importance, as a bulwark against assimilation. And it is for this reason that Chazal introduced prohibitions such as Bishul Akum and Stam Yeinam, so that even in Galus we might retain our national character and existence.

Hence, he explains, Chazal state that even Eliyahu HaNavi will not be allowed to cancel the eighteen decrees that are intended as fences and barriers (Avodah Zarah 36a). Even though he serves as the harbinger of Moshiach, when he comes the Galus is not yet at an end.

When Moshiach comes, however, the enticement for assimilation will no longer exist, as the nations will be subordinate to Am Yisroel. Hence, there will no longer be a need for the decrees that were intended as fences and barriers, and Hashem Himself may overrule them, allowing them to make the preparations of the first Shabbos of Yemos HaMashiach.

(See the Meshech Chochmah's statement there that with the advent of Moshiach and the rebuilding of the Beis HaMikdash, the ruling of R' Zeira that women who are niddos must wait five days before they begin counting their seven clean days [Berachos 31a] will also be nullified, for otherwise a woman will never know when to bring a sacrificial offering because she had been a zavah.)