Skip to content

Commit

Permalink
Opt more targets into size optimizations, per PR feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
stephentoub committed Feb 9, 2021
1 parent 96fb6c3 commit e02c884
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ public static partial class PlatformDetection
public static bool IsThreadingSupported => !IsBrowser;
public static bool IsBinaryFormatterSupported => !IsBrowser;

public static bool IsSpeedOptimized => !IsBrowser;
public static bool IsSizeOptimized => !IsSpeedOptimized;
public static bool IsSpeedOptimized => !IsSizeOptimized;
public static bool IsSizeOptimized => IsBrowser || IsAndroid || IsiOS || IstvOS;

public static bool IsBrowserDomSupported => GetIsBrowserDomSupported();
public static bool IsNotBrowserDomSupported => !IsBrowserDomSupported;
Expand Down
4 changes: 2 additions & 2 deletions src/libraries/System.Linq/src/System.Linq.csproj
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>$(NetCoreAppCurrent);$(NetCoreAppCurrent)-Browser</TargetFrameworks>
<TargetFrameworks>$(NetCoreAppCurrent);$(NetCoreAppCurrent)-Browser;$(NetCoreAppCurrent)-Android;$(NetCoreAppCurrent)-iOS;$(NetCoreAppCurrent)-tvOS</TargetFrameworks>
<Nullable>enable</Nullable>
<OptimizeForSize Condition="'$(TargetsBrowser)' == 'true'">true</OptimizeForSize>
<OptimizeForSize Condition="'$(TargetsBrowser)' == 'true' or '$(TargetsAndroid)' == 'true' or '$(TargetsiOS)' == 'true' or '$(TargetstvOS)' == 'true'">true</OptimizeForSize>
</PropertyGroup>
<ItemGroup Condition="'$(OptimizeForSize)' == true">
<Compile Include="System\Linq\Enumerable.SizeOpt.cs" />
Expand Down

0 comments on commit e02c884

Please sign in to comment.