Explorar o código

Revert "Remove REFERENCE_ASSEMBLY."

This reverts commit f687ae1ec6456adba34d7a3603b2b01101d53028.
Oren Novotny %!s(int64=6) %!d(string=hai) anos
pai
achega
548e59f1c3

+ 8 - 0
Ix.NET/Source/System.Interactive.Providers/System/Linq/QueryableEx.Generated.cs

@@ -2152,7 +2152,11 @@ namespace System.Linq
         [EditorBrowsable(EditorBrowsableState.Never)]
         public static IEnumerable<TSource> TakeLast<TSource>(IEnumerable<TSource> source, int count)
         {
+#if REFERENCE_ASSEMBLY
+            return null;
+#else
             return EnumerableEx.TakeLast(source, count);
+#endif
         }
 #pragma warning restore 1591
 
@@ -2186,7 +2190,11 @@ namespace System.Linq
         [EditorBrowsable(EditorBrowsableState.Never)]
         public static IEnumerable<TSource> SkipLast<TSource>(IEnumerable<TSource> source, int count)
         {
+#if REFERENCE_ASSEMBLY
+            return null;
+#else
             return EnumerableEx.SkipLast(source, count);
+#endif
         }
 #pragma warning restore 1591
 

+ 2 - 2
Ix.NET/Source/System.Interactive/System/Linq/Operators/SkipLast.cs

@@ -8,7 +8,7 @@ namespace System.Linq
 {
     public static partial class EnumerableEx
     {
-#if !(NETCOREAPP2_0 || NETSTANDARD2_1)
+#if !(REFERENCE_ASSEMBLY && (NETCOREAPP2_0 || NETSTANDARD2_1))
         /// <summary>
         /// Bypasses a specified number of contiguous elements from the end of the sequence and returns the remaining elements.
         /// </summary>
@@ -33,6 +33,7 @@ namespace System.Linq
 
             return SkipLastCore(source, count);
         }
+#endif
 
         private static IEnumerable<TSource> SkipLastCore<TSource>(this IEnumerable<TSource> source, int count)
         {
@@ -48,6 +49,5 @@ namespace System.Linq
                 }
             }
         }
-#endif
     }
 }

+ 2 - 2
Ix.NET/Source/System.Interactive/System/Linq/Operators/TakeLast.cs

@@ -8,7 +8,7 @@ namespace System.Linq
 {
     public static partial class EnumerableEx
     {
-#if !(NETCOREAPP2_0 || NETSTANDARD2_1)
+#if !(REFERENCE_ASSEMBLY && (NETCOREAPP2_0 || NETSTANDARD2_1))
         /// <summary>
         /// Returns a specified number of contiguous elements from the end of the sequence.
         /// </summary>
@@ -30,6 +30,7 @@ namespace System.Linq
 
             return TakeLastCore(source, count);
         }
+#endif
 
         private static IEnumerable<TSource> TakeLastCore<TSource>(IEnumerable<TSource> source, int count)
         {
@@ -55,6 +56,5 @@ namespace System.Linq
                 yield return q.Dequeue();
             }
         }
-#endif
     }
 }