It's perfectly safe. There are even tutorials out there on making an 'ice dildo'. I do suggest that you don't take the cube straight out of the tray and put them to use, make sure you run them under water or maybe keep them in a bowl filled with a little water so it doesn't stick.
And do use...