Compounds containing thioaldehyde or thiocetone groups