The Master Nationality Rule is a consequence of Article 4 of the Convention on Certain Questions Relating to the Conflict of Nationality Laws of 1930.
This provides that "a State may not afford diplomatic protection to one of its nationals against a state whose nationality such person also possesses".
The United Kingdom Home Office explains:
In terms of practical effect, it means that when a multiple citizen is in the country of one of his or her nationalities, that country has the right to treat that person as if he or she were solely a citizen or national of that country. This includes the right to impose military service obligations, or to require an exit permit to leave.
The United Kingdom may still make informal diplomatic representations to the authorities of another country when a British citizen is held in another country, even if that person is also a citizen of that country, in case of special humanitarian needs, such as the intervention made by then UK foreign secretary Philip Hammond during the Causeway Bay Books Disappearances.
During the Cold War era, the United States signed consular agreements with certain Warsaw Pact countries providing that a U.S. citizen who entered that country with a U.S. passport and the appropriate visa would not be subsequently treated as a citizen of that country (and hence prevented from leaving). The Warsaw Pact countries involved (notably Poland) wished to encourage tourism from emigrants and their descendants settled in the U.S. Since the dissolution of the Warsaw Pact in 1991, many of those countries have abolished visa requirements for U.S. citizens thus nullifying those provisions (for detailed discussion see under Dual citizenship of Poland).
The United States,Australia and Canada have concluded similar consular agreements with the People's Republic of China.