Are the output pins on the 74HC595 shift register protected against shorting? In the following schematic you can see that Q1 and Q4 both are connected to a Arduino's Digital Input Pin. So if Q1 is high and Q4 is low, would there be current flowing from Q1 through Q4 (and through the chip) to Ground - or is there already some protection inside?



Are the output pins on the 74HC595 shift register protected from connected voltages in the realms of their own VCC? Or do you need to put a diode in?



I feel like this is a very basic question, which makes it very weird that I didn't find an answer to this, already... :-( Am I looking into the wrong resources? I had a look into the provided datasheet, but couldn't find any information. Didn't get any results from searching for existing posts on Stack Exchange or other sites.
In this data sheet it says:


  When the output-enable (OE) input is high,the outputs are in the
  high-impedance state.


However on page 3 you will notice that the *OE pin controls all outputs at the same time.  So if you connect 2 output pins and one is high and the other is low and you hold *OE low ... you will likely burn out the driver for one of the 2 output pins if not the chip its self.

If you add diodes to BOTH outputs you are essentially creating a wired or gate.  (You should add a resistor.  See the examples in the provided link.) This is fine as long as you understand how a wired or gate works.