A Diode can only pass a Signal. Either low voltage, if the cathode is connected to the input, or high voltage, if the anode is connected to the input. In any case, the polarity of the Output is the same as for the input. Look up "Diode Transistor logic" or DTL in e.g.the Wikipedia. You will find that an additional Transistor is required to generate the inverse signal