private static void Skip(ref FuncOptionContext <T> context, out Option <T> next) { context.bd.DetectBacktrack(); if (context.needsMove) { context.acc = context.selector(context.acc.value); } else { context.needsMove = true; } next = context.acc; if (!next.isSome) { context.bd.Release(); } }
private static void Dispose(ref FuncOptionContext <T> context, out Option <T> next) { next = new Option <T>(); context.bd.Release(); }
private static void Remove(ref FuncOptionContext <T> context, out Option <T> next) { throw new NotSupportedException(); }