Final answer:
Metformin is contraindicated in cases of renal disease, alcoholism, and hypoxia but not during pregnancy, where it can be used safely for managing gestational diabetes or pre-existing diabetes with careful monitoring.
Step-by-step explanation:
Metformin is primarily used in the treatment of type 2 diabetes mellitus but it has contraindications that prevent its use in certain conditions due to the risk of a serious side effect called lactic acidosis. Contraindications include renal disease due to the drug's clearance dependence on kidney function, alcoholics due to the increased risk of lactic acidosis, and conditions leading to hypoxia for the same reason. However, metformin is not contraindicated during pregnancy unless there is a specific risk to the patient that outweighs the benefits. Recent guidelines and research suggest that metformin can be used safely during pregnancy for managing gestational diabetes or pre-existing diabetes, with careful monitoring.