This is what Maduro and Chavez before him did in Venezuela. It results in flight of all foreign investment out of the companies and is a terrible idea as a result.
https://en.wikipedia.org/wiki/History_of_the_Venezuelan_oil_...
Granted, the monetary policy certainly helped, but when you spend billions investing in a country to only have that money literally stolen from you, so much so that a court ordered PDVSA to pay Conoco $2 billion, all investment is going to leave the country.