Similarly there are a few crashes on empty sequence. Perhaps we should do nothing in case of empty sequence.