Fixed a few bugs related to begin, end, retro.