private void Delete(int index) { if (_marks[index]) return; _marks[index] = true; _commandsToRemove.Add(new RemoveCommand(_commands, index)); AssertValid(index); }