When rocky planets form that have more carbon than does Earth, vast quantities of diamond may be a natural result. Karen Hopkin reports