예제 #1
0
        } = new OptimizedAsyncEnumerable <TestType>();                                                         // boxes enumerator but public

        public void Method()
        {
            Property00 = new OptimizedAsyncEnumerable <TestType>();
            Property01 = new NonOptimizedAsyncEnumerable <TestType>();

            Property11 = new OptimizedAsyncEnumerable <TestType>(); // boxes enumerator but public
        }
        public IAsyncEnumerable <TestType> field11 = new OptimizedAsyncEnumerable <TestType>(); // boxes enumerator but public

        public void Method()
        {
            field00 = new OptimizedAsyncEnumerable <TestType>();
            field01 = new NonOptimizedAsyncEnumerable <TestType>();

            field11 = new OptimizedAsyncEnumerable <TestType>(); // boxes enumerator but public
        }
예제 #3
0
        public void Method()
        {
            OptimizedAsyncEnumerable <TestType> variable00 = new OptimizedAsyncEnumerable <TestType>();
            IAsyncEnumerable <TestType>         variable01 = new NonOptimizedAsyncEnumerable <TestType>();

            var variable10 = new OptimizedAsyncEnumerable <TestType>();

            variable00 = new OptimizedAsyncEnumerable <TestType>();
            variable01 = new NonOptimizedAsyncEnumerable <TestType>();

            variable10 = new OptimizedAsyncEnumerable <TestType>();
        }
예제 #4
0
        public void Method()
        {
            var a0 = new OptimizedAsyncEnumerable <TestType>().FirstAsync();
            var b0 = new OptimizedAsyncEnumerable <TestType>().FirstOrDefaultAsync();
            var c0 = AsyncEnumerableExtensions.FirstAsync(new OptimizedAsyncEnumerable <TestType>());
            var d0 = AsyncEnumerableExtensions.FirstOrDefaultAsync(new OptimizedAsyncEnumerable <TestType>());

            var a1 = new TestType().SingleAsync();
            var b1 = new TestType().SingleOrDefaultAsync();
            var c1 = NotAsyncEnumerableExtensions.SingleAsync(new TestType());
            var d1 = NotAsyncEnumerableExtensions.SingleOrDefaultAsync(new TestType());

            var c2 = SingleAsync(new TestType());
            var d2 = SingleOrDefaultAsync(new TestType());
        }
 public void Method()
 {
     IAsyncEnumerable <TestType> variable = new OptimizedAsyncEnumerable <TestType>();
 }