Why are the cockpit windshields on the A350 black?
The gold tint on the 787 window is a conductive coating for de-icing. 


  Dreamliner jet flight-deck crews will view the world through commercial aviation's largest windshields by PPG, kept clear of fog and ice with gold and indium-tin oxide heating systems. source


The A350 also has a windshield anti-ice system. It is referred to in this answer. One thing both aircraft have in common is that they use curved windshields. I'm not sure if that adds to the black look. But what does add to the black sunglasses look is that the window frames are painted black.


Source



Btw: There's a thread on Airliners.net where most of them seem to despise the black window frames.