Consider a circuit contains a 5V supply that can provide quite high current, say 2A. Now, on one side of the circuit we have some control device, for example microcontoller, on the other - device that uses quite a lot of power, for example a high-voltage device powered with DC-DC boost converter which converts our 5V to 200V. But, our high-voltage device is controlled via 5V line, so technically we can connect it to MCU output pin with a resistor, to limit current consumption.
Our other option, which is actually my question, is to use optocoupler like 4N25M to split MCU and high-voltage device in such manner that the only things they share are 5V line, GND line and the optocoupler device.
Finally, I can now formulate the question - does it make sense to use optocoupler in such a circuit? When saying "make sense" I mean than when I use optocoupler between sides of the circuit that are completely isolated and doesn't use same power source - optocoupler can protect control device of being damaged in case of input pin of high-voltage device suddenly got connected to HV line (in case of damage for example). But, if two sides of our circuit actually shares same power supply, I am not sure if such usage of optocoupler makes sense at all.