Paul criticised Peter for pretending he was not eating with Gentiles when the Jews would come around. There is no law from God that Jews could not eat food with the Gentiles. Peter was the one being hypocritical. Peter was listening to and fearing men.
Acts 10:28 He said to them: "You are well aware that it is against our law for a Jew to associate with or visit a Gentile.
Acts 11:3
and said, "You went into the house of uncircumcised men and ate with them."
John 18:28
Then the Jewish leaders took Jesus from Caiaphas to the palace of the Roman governor. By now it was early morning, and to avoid ceremonial uncleanness they did not enter the palace, because they wanted to be able to eat the Passover.
Genesis 17:14 Any uncircumcised male, who has not been circumcised in the flesh, will be cut off from his people; he has broken my covenant."
Exodus 12:48 "A foreigner residing among you who wants to celebrate the LORD's Passover must have all the males in his household circumcised; then he may take part like one born in the land. No uncircumcised male may eat it.
Joshua 23:7 Do not associate with these nations that remain among you;
Ezekiel 44:7
In addition to all your other detestable practices, you brought foreigners uncircumcised in heart and flesh into my sanctuary, desecrating my temple while you offered me food, fat and blood, and you broke my covenant.