diff options
author | Marek Safar <marek.safar@gmail.com> | 2010-11-02 16:33:59 +0300 |
---|---|---|
committer | Marek Safar <marek.safar@gmail.com> | 2010-11-02 16:33:59 +0300 |
commit | cefe597544223f7c0723c65b13d2476fd04aedc7 (patch) | |
tree | 1378cc531a8b80d5808daac1857157c353af0fee /mcs/class/dlr | |
parent | 19d94dd7629b2b6992fd2e7790d2fcc1661a5718 (diff) |
Updated to r54115
Diffstat (limited to 'mcs/class/dlr')
125 files changed, 1768 insertions, 1665 deletions
diff --git a/mcs/class/dlr/Runtime/Microsoft.Dynamic/Microsoft.Dynamic.csproj b/mcs/class/dlr/Runtime/Microsoft.Dynamic/Microsoft.Dynamic.csproj index 17b03f9b14f..e7c31692743 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Dynamic/Microsoft.Dynamic.csproj +++ b/mcs/class/dlr/Runtime/Microsoft.Dynamic/Microsoft.Dynamic.csproj @@ -1,531 +1,539 @@ -<?xml version="1.0" encoding="utf-8"?> -<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> - - - <PropertyGroup> - <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> - <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> - <SchemaVersion>2.0</SchemaVersion> - <ProjectGuid>{EB66B766-6354-4208-A3D4-AACBDCB5C3B3}</ProjectGuid> - <OutputType>Library</OutputType> - <AppDesignerFolder>Properties</AppDesignerFolder> - <RootNamespace>Microsoft.Scripting</RootNamespace> - <AssemblyName>Microsoft.Dynamic</AssemblyName> - <WarningsNotAsErrors>1685,618,649</WarningsNotAsErrors> - <NoWarn>1591</NoWarn> -<AssemblyOriginatorKeyFile>$(SolutionDir)Runtime\MSSharedLibKey.snk</AssemblyOriginatorKeyFile> - <SignAssembly Condition="'$(SignAssembly)' == '' And Exists('$(AssemblyOriginatorKeyFile)')">true</SignAssembly> - <SignedSym Condition="'$(SignAssembly)' == 'true'">SIGNED</SignedSym> - <DelaySign>true</DelaySign> - <BaseAddress>859832320</BaseAddress> - <TargetFrameworkVersion>v2.0</TargetFrameworkVersion> - <Silverlight3Path>$(ProgramFiles)\Microsoft Silverlight\3.0.40818.0</Silverlight3Path> - <Silverlight4Path>..\..\Utilities\Silverlight\v4-x86fre</Silverlight4Path> - <!-- The following two lines prevent csc.rsp and Microsoft.NETFramework.props from adding additional assembly references --> - <NoConfig>true</NoConfig> - <AddAdditionalExplicitAssemblyReferences>false</AddAdditionalExplicitAssemblyReferences> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'FxCop|AnyCPU' "> - <DebugType>pdbonly</DebugType> - <Optimize>true</Optimize> -<OutputPath>$(SolutionDir)..\Bin\fxcop\</OutputPath> - <DefineConstants>TRACE;CLR2;$(SignedSym)</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <RunCodeAnalysis>true</RunCodeAnalysis> - <CodeAnalysisRules>-Microsoft.Usage#CA2209;+!Microsoft.Design#CA1012;-!Microsoft.Design#CA2210;+!Microsoft.Design#CA1040;+!Microsoft.Design#CA1005;+!Microsoft.Design#CA1020;-!Microsoft.Design#CA1021;+!Microsoft.Design#CA1010;-!Microsoft.Design#CA1011;+!Microsoft.Design#CA1009;+!Microsoft.Design#CA1050;+!Microsoft.Design#CA1026;+!Microsoft.Design#CA1019;+!Microsoft.Design#CA1031;+!Microsoft.Design#CA1047;-!Microsoft.Design#CA1000;+!Microsoft.Design#CA1048;-!Microsoft.Design#CA1051;-!Microsoft.Design#CA1002;+!Microsoft.Design#CA1061;-!Microsoft.Design#CA1006;+!Microsoft.Design#CA1046;+!Microsoft.Design#CA1045;+!Microsoft.Design#CA1065;+!Microsoft.Design#CA1038;+!Microsoft.Design#CA1008;+!Microsoft.Design#CA1028;+!Microsoft.Design#CA1064;-!Microsoft.Design#CA1004;+!Microsoft.Design#CA1035;-!Microsoft.Design#CA1063;+!Microsoft.Design#CA1032;+!Microsoft.Design#CA1023;-!Microsoft.Design#CA1033;+!Microsoft.Design#CA1039;+!Microsoft.Design#CA1016;+!Microsoft.Design#CA1014;+!Microsoft.Design#CA1017;+!Microsoft.Design#CA1018;+!Microsoft.Design#CA1027;+!Microsoft.Design#CA1059;+!Microsoft.Design#CA1060;+!Microsoft.Design#CA1034;+!Microsoft.Design#CA1013;+!Microsoft.Design#CA1036;+!Microsoft.Design#CA1044;+!Microsoft.Design#CA1041;+!Microsoft.Design#CA1025;+!Microsoft.Design#CA1052;+!Microsoft.Design#CA1053;+!Microsoft.Design#CA1057;+!Microsoft.Design#CA1058;+!Microsoft.Design#CA1001;+!Microsoft.Design#CA1049;+!Microsoft.Design#CA1054;+!Microsoft.Design#CA1056;+!Microsoft.Design#CA1055;+!Microsoft.Design#CA1030;+!Microsoft.Design#CA1003;-!Microsoft.Design#CA1007;+!Microsoft.Design#CA1043;-!Microsoft.Design#CA1024;+!Microsoft.Globalization#CA1301;+!Microsoft.Globalization#CA1302;-!Microsoft.Globalization#CA1308;+!Microsoft.Globalization#CA1306;+!Microsoft.Globalization#CA1304;-!Microsoft.Globalization#CA1305;+!Microsoft.Globalization#CA2101;+!Microsoft.Globalization#CA1300;-!Microsoft.Globalization#CA1307;+!Microsoft.Globalization#CA1309;+!Microsoft.Interoperability#CA1403;+!Microsoft.Interoperability#CA1406;+!Microsoft.Interoperability#CA1413;+!Microsoft.Interoperability#CA1402;+!Microsoft.Interoperability#CA1407;+!Microsoft.Interoperability#CA1404;+!Microsoft.Interoperability#CA1410;+!Microsoft.Interoperability#CA1411;+!Microsoft.Interoperability#CA1405;+!Microsoft.Interoperability#CA1409;+!Microsoft.Interoperability#CA1415;+!Microsoft.Interoperability#CA1408;+!Microsoft.Interoperability#CA1414;+!Microsoft.Interoperability#CA1412;+!Microsoft.Interoperability#CA1400;+!Microsoft.Interoperability#CA1401;+!Microsoft.Maintainability#CA1506;+!Microsoft.Maintainability#CA1502;+!Microsoft.Maintainability#CA1501;+!Microsoft.Maintainability#CA1505;+!Microsoft.Maintainability#CA1504;+!Microsoft.Maintainability#CA1500;+!Microsoft.Mobility#CA1600;+!Microsoft.Mobility#CA1601;-!Microsoft.Naming#CA1702;+!Microsoft.Naming#CA1700;+!Microsoft.Naming#CA1712;+!Microsoft.Naming#CA1713;+!Microsoft.Naming#CA1714;+!Microsoft.Naming#CA1709;-!Microsoft.Naming#CA1704;+!Microsoft.Naming#CA1708;+!Microsoft.Naming#CA1715;-!Microsoft.Naming#CA1710;-!Microsoft.Naming#CA1720;+!Microsoft.Naming#CA1707;+!Microsoft.Naming#CA1722;-!Microsoft.Naming#CA1711;+!Microsoft.Naming#CA1716;+!Microsoft.Naming#CA1717;+!Microsoft.Naming#CA1725;+!Microsoft.Naming#CA1719;-!Microsoft.Naming#CA1721;-!Microsoft.Naming#CA1701;-!Microsoft.Naming#CA1703;+!Microsoft.Naming#CA1724;-!Microsoft.Naming#CA1726;+!Microsoft.Performance#CA1809;-!Microsoft.Performance#CA1811;+!Microsoft.Performance#CA1812;+!Microsoft.Performance#CA1813;+!Microsoft.Performance#CA1823;+!Microsoft.Performance#CA1800;-!Microsoft.Performance#CA1805;+!Microsoft.Performance#CA1810;+!Microsoft.Performance#CA1824;-!Microsoft.Performance#CA1822;+!Microsoft.Performance#CA1815;+!Microsoft.Performance#CA1814;+!Microsoft.Performance#CA1819;+!Microsoft.Performance#CA1821;+!Microsoft.Performance#CA1804;+!Microsoft.Performance#CA1820;+!Microsoft.Performance#CA1802;+!Microsoft.Portability#CA1901;+!Microsoft.Portability#CA1900;+!Microsoft.Reliability#CA2001;+!Microsoft.Reliability#CA2002;+!Microsoft.Reliability#CA2003;+!Microsoft.Reliability#CA2004;+!Microsoft.Reliability#CA2006;+!Microsoft.Security#CA2116;+!Microsoft.Security#CA2117;+!Microsoft.Security#CA2105;+!Microsoft.Security#CA2115;+!Microsoft.Security#CA2102;+!Microsoft.Security#CA2104;+!Microsoft.Security#CA2122;+!Microsoft.Security#CA2114;+!Microsoft.Security#CA2123;+!Microsoft.Security#CA2111;+!Microsoft.Security#CA2108;+!Microsoft.Security#CA2107;+!Microsoft.Security#CA2103;+!Microsoft.Security#CA2118;+!Microsoft.Security#CA2109;+!Microsoft.Security#CA2119;+!Microsoft.Security#CA2106;+!Microsoft.Security#CA2112;+!Microsoft.Security#CA2120;+!Microsoft.Security#CA2121;+!Microsoft.Security#CA2126;+!Microsoft.Security#CA2124;+!Microsoft.Security#CA2127;+!Microsoft.Security#CA2128;+!Microsoft.Security#CA2129;+!Microsoft.Usage#CA2243;+!Microsoft.Usage#CA2236;+!Microsoft.Usage#CA1816;+!Microsoft.Usage#CA2227;+!Microsoft.Usage#CA2213;+!Microsoft.Usage#CA2216;+!Microsoft.Usage#CA2214;+!Microsoft.Usage#CA2222;+!Microsoft.Usage#CA1806;+!Microsoft.Usage#CA2217;+!Microsoft.Usage#CA2212;+!Microsoft.Usage#CA2219;+!Microsoft.Usage#CA2201;+!Microsoft.Usage#CA2228;+!Microsoft.Usage#CA2221;+!Microsoft.Usage#CA2220;+!Microsoft.Usage#CA2240;+!Microsoft.Usage#CA2229;+!Microsoft.Usage#CA2238;+!Microsoft.Usage#CA2207;+!Microsoft.Usage#CA2208;+!Microsoft.Usage#CA2235;+!Microsoft.Usage#CA2237;+!Microsoft.Usage#CA2232;+!Microsoft.Usage#CA2223;+!Microsoft.Usage#CA2211;+!Microsoft.Usage#CA2233;+!Microsoft.Usage#CA2225;+!Microsoft.Usage#CA2226;+!Microsoft.Usage#CA2231;+!Microsoft.Usage#CA2224;+!Microsoft.Usage#CA2218;+!Microsoft.Usage#CA2234;+!Microsoft.Usage#CA2239;+!Microsoft.Usage#CA2200;+!Microsoft.Usage#CA1801;+!Microsoft.Usage#CA2242;+!Microsoft.Usage#CA2205;+!Microsoft.Usage#CA2230</CodeAnalysisRules> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> - <DebugSymbols>true</DebugSymbols> - <DebugType>full</DebugType> - <Optimize>false</Optimize> -<OutputPath>$(SolutionDir)..\Bin\Debug\</OutputPath> -<DocumentationFile>$(OutputPath)\Microsoft.Dynamic.xml</DocumentationFile> - <DefineConstants>DEBUG;TRACE;CLR2;$(SignedSym)</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <RunCodeAnalysis>false</RunCodeAnalysis> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> - <DebugType>pdbonly</DebugType> - <Optimize>true</Optimize> -<OutputPath>$(SolutionDir)..\Bin\Release\</OutputPath> -<DocumentationFile>$(OutputPath)\Microsoft.Dynamic.xml</DocumentationFile> - <DefineConstants>TRACE;CLR2;$(SignedSym)</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <RunCodeAnalysis>false</RunCodeAnalysis> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight Debug|AnyCPU' "> - <DebugSymbols>true</DebugSymbols> -<OutputPath>$(SolutionDir)..\Bin\Silverlight Debug\</OutputPath> - <DefineConstants>TRACE;DEBUG;SILVERLIGHT;CLR2;$(SignedSym)</DefineConstants> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <DebugType>full</DebugType> - <PlatformTarget>AnyCPU</PlatformTarget> - <RunCodeAnalysis>false</RunCodeAnalysis> - <ErrorReport>prompt</ErrorReport> - <NoStdLib>true</NoStdLib> -<DocumentationFile>$(OutputPath)\Microsoft.Dynamic.xml</DocumentationFile> - <NoWarn>1591,618</NoWarn> - <AllowUnsafeBlocks>false</AllowUnsafeBlocks> - <SilverlightBuild>true</SilverlightBuild> - <SilverlightPath Condition="'$(SilverlightPath)' == ''">$(Silverlight3Path)</SilverlightPath> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight Release|AnyCPU' "> -<OutputPath>$(SolutionDir)..\Bin\Silverlight Release\</OutputPath> - <DefineConstants>TRACE;SILVERLIGHT;CLR2;$(SignedSym)</DefineConstants> -<DocumentationFile>$(OutputPath)\Microsoft.Dynamic.xml</DocumentationFile> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <NoWarn>1591,618</NoWarn> - <AllowUnsafeBlocks>false</AllowUnsafeBlocks> - <NoStdLib>true</NoStdLib> - <DebugType>pdbonly</DebugType> - <PlatformTarget>AnyCPU</PlatformTarget> - <ErrorReport>prompt</ErrorReport> - <SilverlightBuild>true</SilverlightBuild> - <SilverlightPath Condition="'$(SilverlightPath)' == ''">$(Silverlight3Path)</SilverlightPath> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'V4 Debug|AnyCPU' "> - <DebugSymbols>true</DebugSymbols> - <DebugType>full</DebugType> - <Optimize>false</Optimize> -<OutputPath>$(SolutionDir)..\Bin\V4 Debug\</OutputPath> -<DocumentationFile>$(OutputPath)\Microsoft.Dynamic.xml</DocumentationFile> - <DefineConstants>DEBUG;TRACE;CLR4;$(SignedSym)</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <RunCodeAnalysis>false</RunCodeAnalysis> - <TargetFrameworkVersion>v4.0</TargetFrameworkVersion> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'V4 Release|AnyCPU' "> - <DebugType>pdbonly</DebugType> - <Optimize>true</Optimize> -<OutputPath>$(SolutionDir)..\Bin\V4 Release\</OutputPath> -<DocumentationFile>$(OutputPath)\Microsoft.Dynamic.xml</DocumentationFile> - <DefineConstants>TRACE;CLR4;$(SignedSym)</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <RunCodeAnalysis>false</RunCodeAnalysis> - <TargetFrameworkVersion>v4.0</TargetFrameworkVersion> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight 4 Debug|AnyCPU' "> - <DebugSymbols>true</DebugSymbols> - <DebugType>full</DebugType> - <Optimize>false</Optimize> -<OutputPath>$(SolutionDir)..\Bin\Debug\</OutputPath> - <DefineConstants>TRACE;DEBUG;SILVERLIGHT;CLR4;$(SignedSym)</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <NoWarn>1591,618</NoWarn> - <AllowUnsafeBlocks>false</AllowUnsafeBlocks> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <CheckForOverflowUnderflow>true</CheckForOverflowUnderflow> - <TargetFrameworkVersion>v4.0</TargetFrameworkVersion> - <NoStdLib>true</NoStdLib> - <PlatformTarget>AnyCPU</PlatformTarget> - <SilverlightBuild>true</SilverlightBuild> - <SilverlightPath Condition="'$(SilverlightPath)' == ''">$(Silverlight4Path)</SilverlightPath> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight 4 Release|AnyCPU' "> - <NoStdLib>true</NoStdLib> - <DebugType>pdbonly</DebugType> - <Optimize>true</Optimize> - <PlatformTarget>AnyCPU</PlatformTarget> -<OutputPath>$(SolutionDir)..\Bin\Release\</OutputPath> - <DefineConstants>TRACE;SILVERLIGHT;CLR4;$(SignedSym)</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <TargetFrameworkVersion>v4.0</TargetFrameworkVersion> - <NoWarn>1591,618</NoWarn> - <AllowUnsafeBlocks>false</AllowUnsafeBlocks> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <SilverlightBuild>true</SilverlightBuild> - <SilverlightPath Condition="'$(SilverlightPath)' == ''">$(Silverlight4Path)</SilverlightPath> - </PropertyGroup> - <ItemGroup> - <Compile Include="..\..\Hosts\Silverlight\SilverlightVersion.cs" Condition=" '$(SilverlightBuild)' == 'true' "> - <Link>Properties\SilverlightVersion.cs</Link> - </Compile> - <Compile Include="Actions\Calls\ActualArguments.cs" /> - <Compile Include="Actions\Calls\ApplicableCandidate.cs" /> - <Compile Include="Actions\Calls\ArgBuilder.cs" /> - <Compile Include="Actions\Calls\ArgumentBinding.cs" /> - <Compile Include="Actions\Calls\BindingResult.cs" /> - <Compile Include="Actions\Calls\BindingTarget.cs" /> - <Compile Include="Actions\Calls\ByRefReturnBuilder.cs" /> - <Compile Include="Actions\Calls\CallFailure.cs" /> - <Compile Include="Actions\Calls\CallFailureReason.cs" /> - <Compile Include="Actions\Calls\CandidateSet.cs" /> - <Compile Include="Actions\Calls\ConversionResult.cs" /> - <Compile Include="Actions\Calls\DefaultArgBuilder.cs" /> - <Compile Include="Actions\Calls\DefaultOverloadResolver.cs" /> - <Compile Include="Actions\Calls\InstanceBuilder.cs" /> - <Compile Include="Actions\Calls\KeywordArgBuilder.cs" /> - <Compile Include="Actions\Calls\KeywordConstructorReturnBuilder.cs" /> - <Compile Include="Actions\Calls\MethodCandidate.cs" /> - <Compile Include="Actions\Calls\NarrowingLevel.cs" /> - <Compile Include="Actions\Calls\OutArgBuilder.cs" /> - <Compile Include="Actions\Calls\OverloadInfo.cs" /> - <Compile Include="Actions\Calls\OverloadResolver.cs" /> - <Compile Include="Actions\Calls\OverloadResolverFactory.cs" /> - <Compile Include="Actions\Calls\ParameterMapping.cs" /> - <Compile Include="Actions\Calls\ParameterWrapper.cs" /> - <Compile Include="Actions\Calls\ParamsArgBuilder.cs" /> - <Compile Include="Actions\Calls\ParamsDictArgBuilder.cs" /> - <Compile Include="Actions\Calls\ReferenceArgBuilder.cs" /> - <Compile Include="Actions\Calls\RestrictedArguments.cs" /> - <Compile Include="Actions\Calls\ReturnBuilder.cs" /> - <Compile Include="Actions\Calls\ReturnReferenceArgBuilder.cs" /> - <Compile Include="Actions\Calls\SimpleArgBuilder.cs" /> - <Compile Include="Actions\Calls\TypeInferer.cs" /> - <Compile Include="Actions\ConversionResultKind.cs" /> - <Compile Include="Actions\DefaultBinder.Operations.cs" /> - <Compile Include="Actions\Interceptor.cs" /> - <Compile Include="Actions\DynamicSiteHelper.cs" /> - <Compile Include="Actions\ExtensionBinaryOperationBinder.cs" /> - <Compile Include="Actions\ExtensionUnaryOperationBinder.cs" /> - <Compile Include="Actions\MemberRequestKind.cs" /> - <Compile Include="Actions\OperationBinder.cs" /> - <Compile Include="Actions\OperationMetaObject.cs" /> - <Compile Include="Ast\BlockBuilder.cs" /> - <Compile Include="Ast\ExpressionCollectionBuilder.cs" /> - <Compile Include="Ast\FinallyFlowControlExpression.cs" /> - <Compile Include="Ast\FlowControlRewriter.cs" /> - <Compile Include="Ast\SourceFileInformation.cs" /> - <Compile Include="Ast\SkipInterpretExpression.cs" /> - <Compile Include="Ast\LightDynamicExpression.cs" /> - <Compile Include="Ast\Utils.cs" /> - <Compile Include="Ast\VariableDictionaryExpression.cs" /> - <Compile Include="Ast\NewArrayExpression.cs" /> - <Compile Include="Ast\NewExpression.cs" /> - <Compile Include="Ast\UnaryExpression.cs" /> - <Compile Include="ComInterop\ArgBuilder.cs" /> - <Compile Include="ComInterop\BoolArgBuilder.cs" /> - <Compile Include="ComInterop\BoundDispEvent.cs" /> - <Compile Include="ComInterop\CollectionExtensions.cs" /> - <Compile Include="ComInterop\ComBinder.cs" /> - <Compile Include="ComInterop\ComBinderHelpers.cs" /> - <Compile Include="ComInterop\ComClassMetaObject.cs" /> - <Compile Include="ComInterop\ComDispIds.cs" /> - <Compile Include="ComInterop\ComEventDesc.cs" /> - <Compile Include="ComInterop\ComEventSink.cs" /> - <Compile Include="ComInterop\ComEventSinkProxy.cs" /> - <Compile Include="ComInterop\ComEventSinksContainer.cs" /> - <Compile Include="ComInterop\ComFallbackMetaObject.cs" /> - <Compile Include="ComInterop\ComHresults.cs" /> - <Compile Include="ComInterop\ComInterop.cs" /> - <Compile Include="ComInterop\ComInvokeAction.cs" /> - <Compile Include="ComInterop\ComInvokeBinder.cs" /> - <Compile Include="ComInterop\ComMetaObject.cs" /> - <Compile Include="ComInterop\ComMethodDesc.cs" /> - <Compile Include="ComInterop\ComObject.cs" /> - <Compile Include="ComInterop\ComParamDesc.cs" /> - <Compile Include="ComInterop\ComRuntimeHelpers.cs" /> - <Compile Include="ComInterop\ComType.cs" /> - <Compile Include="ComInterop\ComTypeClassDesc.cs" /> - <Compile Include="ComInterop\ComTypeDesc.cs" /> - <Compile Include="ComInterop\ComTypeEnumDesc.cs" /> - <Compile Include="ComInterop\ComTypeLibDesc.cs" /> - <Compile Include="ComInterop\ComTypeLibInfo.cs" /> - <Compile Include="ComInterop\ComTypeLibMemberDesc.cs" /> - <Compile Include="ComInterop\ConversionArgBuilder.cs" /> - <Compile Include="ComInterop\ConvertArgBuilder.cs" /> - <Compile Include="ComInterop\ConvertibleArgBuilder.cs" /> - <Compile Include="ComInterop\CurrencyArgBuilder.cs" /> - <Compile Include="ComInterop\DateTimeArgBuilder.cs" /> - <Compile Include="ComInterop\DispatchArgBuilder.cs" /> - <Compile Include="ComInterop\DispCallable.cs" /> - <Compile Include="ComInterop\DispCallableMetaObject.cs" /> - <Compile Include="ComInterop\ErrorArgBuilder.cs" /> - <Compile Include="ComInterop\Errors.cs" /> - <Compile Include="ComInterop\ExcepInfo.cs" /> - <Compile Include="ComInterop\Helpers.cs" /> - <Compile Include="ComInterop\IDispatchComObject.cs" /> - <Compile Include="ComInterop\IDispatchMetaObject.cs" /> - <Compile Include="ComInterop\IPseudoComObject.cs" /> - <Compile Include="ComInterop\NullArgBuilder.cs" /> - <Compile Include="ComInterop\SimpleArgBuilder.cs" /> - <Compile Include="ComInterop\SplatCallSite.cs" /> - <Compile Include="ComInterop\StringArgBuilder.cs" /> - <Compile Include="ComInterop\TypeEnumMetaObject.cs" /> - <Compile Include="ComInterop\TypeLibInfoMetaObject.cs" /> - <Compile Include="ComInterop\TypeLibMetaObject.cs" /> - <Compile Include="ComInterop\TypeUtils.cs" /> - <Compile Include="ComInterop\UnknownArgBuilder.cs" /> - <Compile Include="ComInterop\VarEnumSelector.cs" /> - <Compile Include="ComInterop\Variant.cs" /> - <Compile Include="ComInterop\VariantArgBuilder.cs" /> - <Compile Include="ComInterop\VariantArray.cs" /> - <Compile Include="ComInterop\VariantBuilder.cs" /> - <Compile Include="Generation\FieldBuilderExpression.cs" /> - <Compile Include="Hosting\Shell\ICommandDispatcher.cs" /> - <Compile Include="Hosting\Shell\Remote\ConsoleRestartManager.cs" /> - <Compile Include="Hosting\Shell\Remote\RemoteCommandDispatcher.cs" /> - <Compile Include="Hosting\Shell\Remote\RemoteConsoleCommandLine.cs" /> - <Compile Include="Hosting\Shell\Remote\RemoteConsoleHost.cs" /> - <Compile Include="Hosting\Shell\Remote\RemoteRuntimeServer.cs" /> - <Compile Include="Interpreter\BranchLabel.cs" /> - <Compile Include="Interpreter\Instructions\AddInstruction.cs" /> - <Compile Include="Interpreter\Instructions\ArrayOperations.cs" /> - <Compile Include="Interpreter\Instructions\CallInstruction.cs" /> - <Compile Include="Interpreter\Instructions\CallInstruction.Generated.cs" /> - <Compile Include="Interpreter\Instructions\ControlFlowInstructions.cs" /> - <Compile Include="Interpreter\Instructions\DivInstruction.cs" /> - <Compile Include="Interpreter\Instructions\DynamicSplatInstruction.cs" /> - <Compile Include="Interpreter\Instructions\EqualInstruction.cs" /> - <Compile Include="Interpreter\Instructions\FieldOperations.cs" /> - <Compile Include="Interpreter\Instructions\GreaterThanInstruction.cs" /> - <Compile Include="Interpreter\Instructions\InstructionFactory.cs" /> - <Compile Include="Interpreter\Instructions\LessThanInstruction.cs" /> - <Compile Include="Interpreter\Instructions\LocalAccess.cs" /> - <Compile Include="Interpreter\Instructions\InstructionList.cs" /> - <Compile Include="Interpreter\Instructions\NotEqualInstruction.cs" /> - <Compile Include="Interpreter\Instructions\NumericConvertInstruction.cs" /> - <Compile Include="Interpreter\Instructions\StackOperations.cs" /> - <Compile Include="Interpreter\Instructions\TypeOperations.cs" /> - <Compile Include="Interpreter\ILightCallSiteBinder.cs" /> - <Compile Include="Interpreter\LightDelegateCreator.cs" /> - <Compile Include="Interpreter\LightLambda.Generated.cs" /> - <Compile Include="Interpreter\Interpreter.cs" /> - <Compile Include="Interpreter\Instructions\DynamicInstructions.Generated.cs" /> - <Compile Include="Interpreter\Instructions\DynamicInstructionN.cs" /> - <Compile Include="Interpreter\LightLambdaClosureVisitor.cs" /> - <Compile Include="Interpreter\LightLambda.cs" /> - <Compile Include="Interpreter\Instructions\Instruction.cs" /> - <Compile Include="Interpreter\LightCompiler.cs" /> - <Compile Include="Interpreter\LocalVariables.cs" /> - <Compile Include="Interpreter\LoopCompiler.cs" /> - <Compile Include="Interpreter\RuntimeVariables.cs" /> - <Compile Include="Interpreter\InterpretedFrame.cs" /> - <Compile Include="Interpreter\LastFaultingLineExpression.cs" /> - <Compile Include="Math\BigIntegerV2.cs" /> - <Compile Include="Math\BigIntegerV4.cs" /> - <Compile Include="Runtime\ArgumentArray.cs" /> - <Compile Include="Runtime\BindingRestrictionsHelpers.cs" /> - <Compile Include="Runtime\DynamicDelegateCreator.cs" /> - <Compile Include="Runtime\DynamicNull.cs" /> - <Compile Include="Runtime\Generator.cs" /> - <Compile Include="Ast\GeneratorExpression.cs" /> - <Compile Include="Ast\GeneratorRewriter.cs" /> - <Compile Include="Ast\SymbolConstantExpression.cs" /> - <Compile Include="Actions\Calls\Candidate.cs" /> - <Compile Include="Ast\YieldExpression.cs" /> - <Compile Include="Generation\DelegateHelpers.cs" /> - <Compile Include="Generation\DelegateHelpers.Generated.cs" /> - <Compile Include="Generation\AssemblyGen.cs" /> - <Compile Include="Generation\ConstantCheck.cs" /> - <Compile Include="Generation\DynamicILGen.cs" /> - <Compile Include="Generation\ILGen.cs" /> - <Compile Include="Generation\KeyedQueue.cs" /> - <Compile Include="Generation\Snippets.cs" /> - <Compile Include="Generation\TypeGen.cs" /> - <Compile Include="Actions\ComboActionRewriter.cs" /> - <Compile Include="Actions\ComboBinder.cs" /> - <Compile Include="Actions\ConditionalBuilder.cs" /> - <Compile Include="Actions\DefaultBinder.Conversions.cs" /> - <Compile Include="Actions\DefaultBinder.DeleteMember.cs" /> - <Compile Include="Actions\DefaultBinder.GetMember.cs" /> - <Compile Include="Actions\DefaultBinder.Invoke.cs" /> - <Compile Include="Actions\DefaultBinder.MethodCalls.cs" /> - <Compile Include="Actions\DefaultBinder.SetMember.cs" /> - <Compile Include="Actions\DefaultBinder.cs" /> - <Compile Include="Actions\NoSideEffectsAttribute.cs" /> - <Compile Include="Actions\OperatorInfo.cs" /> - <Compile Include="Ast\BinaryExpression.cs" /> - <Compile Include="Ast\Block.cs" /> - <Compile Include="Ast\ConstantExpression.cs" /> - <Compile Include="Ast\EmptyStatements.cs" /> - <Compile Include="Ast\LambdaBuilder.cs" /> - <Compile Include="Ast\LambdaParameterRewriter.cs" /> - <Compile Include="Ast\LoopStatement.cs" /> - <Compile Include="Ast\MethodCallExpression.cs" /> - <Compile Include="Ast\TryStatementBuilder.cs" /> - <Compile Include="MultiRuntimeAwareAttribute.cs" /> - <Compile Include="PerfTrack.cs" /> - <Compile Include="Runtime\CompilerContext.cs" /> - <Compile Include="Runtime\DynamicLanguageProviderAttribute.cs" /> - <Compile Include="Runtime\IConvertibleMetaObject.cs" /> - <Compile Include="Runtime\ICustomScriptCodeData.cs" /> - <Compile Include="Runtime\IRestrictedMetaObject.cs" /> - <Compile Include="Runtime\LegacyScriptCode.cs" /> - <Compile Include="Runtime\MetaObjectExtensions.cs" /> - <Compile Include="Runtime\RestrictedMetaObject.cs" /> - <Compile Include="Runtime\SavableScriptCode.cs" /> - <Compile Include="Runtime\TokenizerBuffer.cs" /> - <Compile Include="Generation\MethodSignatureInfo.cs" /> - <Compile Include="Hosting\Shell\BasicConsole.cs" /> - <Compile Include="Hosting\Shell\CommandLine.cs" /> - <Compile Include="Hosting\Shell\ConsoleHost.cs" /> - <Compile Include="Hosting\Shell\ConsoleHostOptions.cs" /> - <Compile Include="Hosting\Shell\ConsoleHostOptionsParser.cs" /> - <Compile Include="Hosting\Shell\ConsoleOptions.cs" /> - <Compile Include="Hosting\Shell\IConsole.cs" /> - <Compile Include="Hosting\Shell\OptionsParser.cs" /> - <Compile Include="Hosting\Shell\Style.cs" /> - <Compile Include="Hosting\Shell\SuperConsole.cs" /> - <Compile Include="GlobalSuppressions.cs" /> - <Compile Include="Math\Complex64.cs" /> - <Compile Include="Properties\AssemblyInfo.cs" /> - <Compile Include="Runtime\AmbiguousFileNameException.cs" /> - <Compile Include="Runtime\BinderOps.cs" /> - <Compile Include="Runtime\CallTypes.cs" /> - <Compile Include="Runtime\Cast.Generated.cs" /> - <Compile Include="Runtime\Cast.cs" /> - <Compile Include="Runtime\CodeDomCodeGen.cs" /> - <Compile Include="Runtime\DelegateInfo.cs" /> - <Compile Include="Runtime\DelegateSignatureInfo.cs" /> - <Compile Include="Runtime\ISlice.cs" /> - <Compile Include="Runtime\IdDispenser.cs" /> - <Compile Include="Runtime\LanguageBoundTextContentProvider.cs" /> - <Compile Include="Runtime\LocalsDictionary.cs" /> - <Compile Include="Runtime\PositionTrackingWriter.cs" /> - <Compile Include="Runtime\ReturnFixer.cs" /> - <Compile Include="Runtime\SourceStringContentProvider.cs" /> - <Compile Include="Utils\CacheDict.cs" /> - <Compile Include="Utils\CollectionExtensions.cs" /> - <Compile Include="Utils\CopyOnWriteList.cs" /> - <Compile Include="Utils\DynamicUtils.cs" /> - <Compile Include="Utils\EnumUtils.cs" /> - <Compile Include="Utils\ListEqualityComparer.cs" /> - <Compile Include="Utils\MathUtils.cs" /> - <Compile Include="Utils\MonitorUtils.cs" /> - <Compile Include="Utils\Publisher.cs" /> - <Compile Include="Utils\ReadOnlyDictionary.cs" /> - <Compile Include="Utils\ReferenceEqualityComparer.cs" /> - <Compile Include="Utils\HashSet.cs" /> - <Compile Include="Utils\SynchronizedDictionary.cs" /> - <Compile Include="Utils\ThreadLocal.cs" /> - <Compile Include="Utils\TypeUtils.cs" /> - <Compile Include="Utils\ValueArray.cs" /> - <Compile Include="Utils\WeakCollection.cs" /> - <Compile Include="Utils\WeakDictionary.cs" /> - <Compile Include="Utils\WeakHandle.cs" /> - <Compile Include="DebugOptions.cs" /> - <Compile Include="SpecSharp.cs" /> - <Compile Include="MutableTuple.cs" /> - <Compile Include="Actions\ActionBinder.cs" /> - <Compile Include="Actions\Argument.cs" /> - <Compile Include="Actions\ArgumentType.cs" /> - <Compile Include="Actions\BoundMemberTracker.cs" /> - <Compile Include="Actions\CallSignature.cs" /> - <Compile Include="Actions\ConstructorTracker.cs" /> - <Compile Include="Actions\CustomTracker.cs" /> - <Compile Include="Actions\ErrorInfo.cs" /> - <Compile Include="Actions\EventTracker.cs" /> - <Compile Include="Actions\ExtensionMethodTracker.cs" /> - <Compile Include="Actions\ExtensionPropertyTracker.cs" /> - <Compile Include="Actions\FieldTracker.cs" /> - <Compile Include="Actions\MemberGroup.cs" /> - <Compile Include="Actions\MemberTracker.cs" /> - <Compile Include="Actions\MethodGroup.cs" /> - <Compile Include="Actions\MethodTracker.cs" /> - <Compile Include="Actions\NamespaceTracker.cs" /> - <Compile Include="Actions\NestedTypeTracker.cs" /> - <Compile Include="Actions\PropertyTracker.cs" /> - <Compile Include="Actions\ReflectedPropertyTracker.cs" /> - <Compile Include="Actions\TopNamespaceTracker.cs" /> - <Compile Include="Actions\TrackerTypes.cs" /> - <Compile Include="Actions\TypeGroup.cs" /> - <Compile Include="Actions\TypeTracker.cs" /> - <Compile Include="Ast\DebugStatement.cs" /> - <Compile Include="Ast\IfStatementBuilder.cs" /> - <Compile Include="Ast\IfStatementTest.cs" /> - <Compile Include="Generation\CompilerHelpers.cs" /> - <Compile Include="Generation\IExpressionSerializable.cs" /> - <Compile Include="Generation\ToDiskRewriter.cs" /> - <Compile Include="Runtime\AssemblyTypeNames.cs" /> - <Compile Include="Runtime\BaseSymbolDictionary.cs" /> - <Compile Include="Runtime\BinderType.cs" /> - <Compile Include="Runtime\CallTargets.cs" /> - <Compile Include="Runtime\CustomSymbolDictionary.cs" /> - <Compile Include="Runtime\DlrCachedCodeAttribute.cs" /> - <Compile Include="Runtime\DocumentationAttribute.cs" /> - <Compile Include="Runtime\ExceptionHelpers.cs" /> - <Compile Include="Runtime\ExplicitConversionMethodAttribute.cs" /> - <Compile Include="Runtime\Extensible.cs" /> - <Compile Include="Runtime\ExtensionTypeAttribute.cs" /> - <Compile Include="Runtime\ExtraKeyEnumerator.cs" /> - <Compile Include="Runtime\IMembersList.cs" /> - <Compile Include="Runtime\ImplicitConversionMethodAttribute.cs" /> - <Compile Include="Runtime\ModuleChangeEventArgs.cs" /> - <Compile Include="Runtime\ModuleChangeEventType.cs" /> - <Compile Include="Runtime\NullTextContentProvider.cs" /> - <Compile Include="Runtime\OperationFailed.cs" /> - <Compile Include="Runtime\OperatorSlotAttribute.cs" /> - <Compile Include="Runtime\PropertyMethodAttribute.cs" /> - <Compile Include="Runtime\ReflectionCache.cs" /> - <Compile Include="Runtime\ScriptingRuntimeHelpers.cs" /> - <Compile Include="Runtime\StaticExtensionMethodAttribute.cs" /> - <Compile Include="Runtime\SymbolDictionary.cs" /> - <Compile Include="Runtime\TransformDictEnumerator.cs" /> - <Compile Include="Runtime\Uninitialized.cs" /> - <Compile Include="Utils\ArrayUtils.cs" /> - <Compile Include="Utils\AssemblyQualifiedTypeName.cs" /> - <Compile Include="Utils\Assert.cs" /> - <Compile Include="Utils\CheckedDictionaryEnumerator.cs" /> - <Compile Include="Utils\CollectionUtils.cs" /> - <Compile Include="Utils\ContractUtils.cs" /> - <Compile Include="Utils\DictionaryUnionEnumerator.cs" /> - <Compile Include="Utils\ExceptionFactory.Generated.cs" /> - <Compile Include="Utils\ExceptionUtils.cs" /> - <Compile Include="Utils\IOUtils.cs" /> - <Compile Include="Utils\ReflectionUtils.cs" /> - <Compile Include="Utils\StringUtils.cs" /> - <Compile Include="Utils\TextStream.cs" /> - <Compile Include="IValueEquality.cs" /> - <Compile Include="KeyboardInterruptException.cs" /> - <Compile Include="SourceFileContentProvider.cs" /> - </ItemGroup> - <ItemGroup Condition=" '$(SilverlightBuild)' != 'true' "> - <Reference Include="System" /> - <Reference Include="System.Xml" /> - <Reference Include="System.Configuration" /> - <Reference Include="System.Numerics" Condition=" '$(TargetFrameworkVersion)' == 'v4.0' " /> - <Reference Include="System.Core" Condition=" '$(TargetFrameworkVersion)' == 'v4.0' " /> - <Reference Include="System.Data" /> - <Reference Include="System.Runtime.Remoting" /> - </ItemGroup> - <ItemGroup Condition=" '$(SilverlightBuild)' == 'true' "> - <Reference Include="mscorlib, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e"> - <SpecificVersion>False</SpecificVersion> - <HintPath>$(SilverlightPath)\mscorlib.dll</HintPath> - </Reference> - <Reference Include="System, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e"> - <SpecificVersion>False</SpecificVersion> - <HintPath>$(SilverlightPath)\System.dll</HintPath> - </Reference> - <Reference Include="System.Core, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" Condition=" '$(TargetFrameworkVersion)' == 'v4.0' "> - <SpecificVersion>False</SpecificVersion> - <HintPath>$(SilverlightPath)\System.Core.dll</HintPath> - </Reference> - <Reference Include="System.Numerics, Version=2.0.5.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" Condition="'$(TargetFrameworkVersion)' == 'v4.0' "> - <SpecificVersion>False</SpecificVersion> - <HintPath>$(SilverlightPath)\System.Numerics.dll</HintPath> - </Reference> - </ItemGroup> - <ItemGroup> - <ProjectReference Include="..\Microsoft.Scripting.Core\Microsoft.Scripting.Core.csproj" Condition="'$(TargetFrameworkVersion)' != 'v4.0'"> - <Project>{2AE75F5A-CD1F-4925-9647-AF4D1C282FB4}</Project> - <Name>Microsoft.Scripting.Core</Name> - <Private>False</Private> - </ProjectReference> - <ProjectReference Include="..\Microsoft.Scripting.Core\Microsoft.Scripting.ExtensionAttribute.csproj" Condition="'$(TargetFrameworkVersion)' != 'v4.0'"> - <Project>{8B0F1074-750E-4D64-BF23-A1E0F54261E5}</Project> - <Name>Microsoft.Scripting.ExtensionAttribute</Name> - </ProjectReference> - <ProjectReference Include="..\Microsoft.Scripting\Microsoft.Scripting.csproj"> - <Project>{02FF0909-F5AD-48CF-A86A-345E721B7E40}</Project> - <Name>Microsoft.Scripting</Name> - </ProjectReference> - </ItemGroup> - <ItemGroup> - <Content Include="Microsoft.Scripting.txt" /> - </ItemGroup> - <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" Condition=" '$(SilverlightTreeBuild)' != 'true' " /> -</Project> +<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
+ <Import Project="$(SolutionDir)..\Solutions\Common.proj" />
+
+ <PropertyGroup>
+ <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
+ <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
+ <SchemaVersion>2.0</SchemaVersion>
+ <ProjectGuid>{EB66B766-6354-4208-A3D4-AACBDCB5C3B3}</ProjectGuid>
+ <OutputType>Library</OutputType>
+ <AppDesignerFolder>Properties</AppDesignerFolder>
+ <RootNamespace>Microsoft.Scripting</RootNamespace>
+ <AssemblyName>Microsoft.Dynamic</AssemblyName>
+ <DocumentationFile>$(SolutionDir)..\bin\$(Configuration)\Microsoft.Dynamic.xml</DocumentationFile>
+ <TreatWarningsAsErrors>true</TreatWarningsAsErrors>
+ <WarningsNotAsErrors>618</WarningsNotAsErrors>
+ <NoWarn>1591</NoWarn>
+ <BaseAddress>859832320</BaseAddress>
+ <CodeAnalysisRuleSet>Microsoft.Dynamic.ruleset</CodeAnalysisRuleSet>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'FxCop|AnyCPU' ">
+ <DebugType>pdbonly</DebugType>
+ <Optimize>true</Optimize>
+ <OutputPath>$(SolutionDir)..\bin\FxCop</OutputPath>
+ <DefineConstants>TRACE;CLR4;$(SignedSym)</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <RunCodeAnalysis>true</RunCodeAnalysis>
+ <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'v2Debug|AnyCPU' ">
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>full</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>$(SolutionDir)..\bin\v2Debug</OutputPath>
+ <DefineConstants>DEBUG;TRACE;CLR2;$(SignedSym)</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <RunCodeAnalysis>false</RunCodeAnalysis>
+ <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'v2Release|AnyCPU' ">
+ <DebugType>pdbonly</DebugType>
+ <Optimize>true</Optimize>
+ <OutputPath>$(SolutionDir)..\bin\v2Release</OutputPath>
+ <DefineConstants>TRACE;CLR2;$(SignedSym)</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <RunCodeAnalysis>false</RunCodeAnalysis>
+ <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight3Debug|AnyCPU' ">
+ <DebugSymbols>true</DebugSymbols>
+ <OutputPath>$(SolutionDir)..\bin\Silverlight3Debug</OutputPath>
+ <DefineConstants>TRACE;DEBUG;SILVERLIGHT;CLR2;$(SignedSym)</DefineConstants>
+ <DebugType>full</DebugType>
+ <PlatformTarget>AnyCPU</PlatformTarget>
+ <RunCodeAnalysis>false</RunCodeAnalysis>
+ <ErrorReport>prompt</ErrorReport>
+ <AllowUnsafeBlocks>false</AllowUnsafeBlocks>
+ <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight3Release|AnyCPU' ">
+ <OutputPath>$(SolutionDir)..\bin\Silverlight3Release</OutputPath>
+ <DefineConstants>TRACE;SILVERLIGHT;CLR2;$(SignedSym)</DefineConstants>
+ <AllowUnsafeBlocks>false</AllowUnsafeBlocks>
+ <DebugType>pdbonly</DebugType>
+ <PlatformTarget>AnyCPU</PlatformTarget>
+ <ErrorReport>prompt</ErrorReport>
+ <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>full</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>$(SolutionDir)..\bin\Debug</OutputPath>
+ <DefineConstants>DEBUG;TRACE;CLR4;$(SignedSym)</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <RunCodeAnalysis>false</RunCodeAnalysis>
+ <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
+ <DebugType>pdbonly</DebugType>
+ <Optimize>true</Optimize>
+ <OutputPath>$(SolutionDir)..\bin\Release</OutputPath>
+ <DefineConstants>TRACE;CLR4;$(SignedSym)</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <RunCodeAnalysis>false</RunCodeAnalysis>
+ <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight4Debug|AnyCPU' ">
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>full</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>$(SolutionDir)..\bin\Silverlight4Debug</OutputPath>
+ <DefineConstants>TRACE;DEBUG;SILVERLIGHT;CLR4;$(SignedSym)</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <AllowUnsafeBlocks>false</AllowUnsafeBlocks>
+ <CheckForOverflowUnderflow>true</CheckForOverflowUnderflow>
+ <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
+ <PlatformTarget>AnyCPU</PlatformTarget>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight4Release|AnyCPU' ">
+ <DebugType>pdbonly</DebugType>
+ <Optimize>true</Optimize>
+ <PlatformTarget>AnyCPU</PlatformTarget>
+ <OutputPath>$(SolutionDir)..\bin\Silverlight4Release</OutputPath>
+ <DefineConstants>TRACE;SILVERLIGHT;CLR4;$(SignedSym)</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
+ <AllowUnsafeBlocks>false</AllowUnsafeBlocks>
+ </PropertyGroup>
+ <ItemGroup>
+ <Compile Include="..\..\Hosts\Silverlight\SilverlightVersion.cs" Condition=" '$(SilverlightBuild)' == 'true' ">
+ <Link>Properties\SilverlightVersion.cs</Link>
+ </Compile>
+ <Compile Include="Actions\Calls\ActualArguments.cs" />
+ <Compile Include="Actions\Calls\ApplicableCandidate.cs" />
+ <Compile Include="Actions\Calls\ArgBuilder.cs" />
+ <Compile Include="Actions\Calls\ArgumentBinding.cs" />
+ <Compile Include="Actions\Calls\BindingResult.cs" />
+ <Compile Include="Actions\Calls\BindingTarget.cs" />
+ <Compile Include="Actions\Calls\ByRefReturnBuilder.cs" />
+ <Compile Include="Actions\Calls\CallFailure.cs" />
+ <Compile Include="Actions\Calls\CallFailureReason.cs" />
+ <Compile Include="Actions\Calls\CandidateSet.cs" />
+ <Compile Include="Actions\Calls\ConversionResult.cs" />
+ <Compile Include="Actions\Calls\DefaultArgBuilder.cs" />
+ <Compile Include="Actions\Calls\DefaultOverloadResolver.cs" />
+ <Compile Include="Actions\Calls\InstanceBuilder.cs" />
+ <Compile Include="Actions\Calls\KeywordArgBuilder.cs" />
+ <Compile Include="Actions\Calls\KeywordConstructorReturnBuilder.cs" />
+ <Compile Include="Actions\Calls\MethodCandidate.cs" />
+ <Compile Include="Actions\Calls\NarrowingLevel.cs" />
+ <Compile Include="Actions\Calls\OutArgBuilder.cs" />
+ <Compile Include="Actions\Calls\OverloadInfo.cs" />
+ <Compile Include="Actions\Calls\OverloadResolver.cs" />
+ <Compile Include="Actions\Calls\OverloadResolverFactory.cs" />
+ <Compile Include="Actions\Calls\ParameterMapping.cs" />
+ <Compile Include="Actions\Calls\ParameterWrapper.cs" />
+ <Compile Include="Actions\Calls\ParamsArgBuilder.cs" />
+ <Compile Include="Actions\Calls\ParamsDictArgBuilder.cs" />
+ <Compile Include="Actions\Calls\ReferenceArgBuilder.cs" />
+ <Compile Include="Actions\Calls\RestrictedArguments.cs" />
+ <Compile Include="Actions\Calls\ReturnBuilder.cs" />
+ <Compile Include="Actions\Calls\ReturnReferenceArgBuilder.cs" />
+ <Compile Include="Actions\Calls\SimpleArgBuilder.cs" />
+ <Compile Include="Actions\Calls\TypeInferer.cs" />
+ <Compile Include="Actions\ConversionResultKind.cs" />
+ <Compile Include="Actions\DefaultBinder.Operations.cs" />
+ <Compile Include="Actions\Interceptor.cs" />
+ <Compile Include="Actions\DynamicSiteHelper.cs" />
+ <Compile Include="Actions\ExtensionBinaryOperationBinder.cs" />
+ <Compile Include="Actions\ExtensionUnaryOperationBinder.cs" />
+ <Compile Include="Actions\MemberRequestKind.cs" />
+ <Compile Include="Actions\OperationBinder.cs" />
+ <Compile Include="Actions\OperationMetaObject.cs" />
+ <Compile Include="Ast\BlockBuilder.cs" />
+ <Compile Include="Ast\ExpressionCollectionBuilder.cs" />
+ <Compile Include="Ast\FinallyFlowControlExpression.cs" />
+ <Compile Include="Ast\FlowControlRewriter.cs" />
+ <Compile Include="Ast\ILightExceptionAwareExpression.cs" />
+ <Compile Include="Actions\ILightExceptionBinder.cs" />
+ <Compile Include="Ast\LightCheckAndThrowExpression.cs" />
+ <Compile Include="Ast\LightExceptionConvertingExpression.cs" />
+ <Compile Include="Ast\LightLambdaExpression.cs" />
+ <Compile Include="Ast\LightThrowExpression.cs" />
+ <Compile Include="Debugging\CollectionUtils.cs" />
+ <Compile Include="Debugging\CompilerServices\DebugLambdaInfo.cs" />
+ <Compile Include="Debugging\CompilerServices\IDebugCompilerSupport.cs" />
+ <Compile Include="Debugging\DebugContext.cs" />
+ <Compile Include="Debugging\DebugContext.GeneratorLoopProc.cs" />
+ <Compile Include="Debugging\DebugFrame.cs" />
+ <Compile Include="Debugging\DebuggableLambdaBuilder.cs" />
+ <Compile Include="Debugging\DebugGenerator.cs" />
+ <Compile Include="Debugging\DebugInfoRewriter.cs" />
+ <Compile Include="Debugging\DebugMode.cs" />
+ <Compile Include="Debugging\DebugSourceFile.cs" />
+ <Compile Include="Debugging\DebugSourceSpan.cs" />
+ <Compile Include="Debugging\DebugThread.cs" />
+ <Compile Include="Debugging\DefaultRuntimeVariablesImpl\DebugRuntimeVariables.cs" />
+ <Compile Include="Debugging\DefaultRuntimeVariablesImpl\DefaultDebugThread.cs" />
+ <Compile Include="Debugging\DefaultRuntimeVariablesImpl\DefaultDebugThreadFactory.cs" />
+ <Compile Include="Debugging\DelegateHelpers.cs" />
+ <Compile Include="Debugging\ForceToGeneratorLoopException.cs" />
+ <Compile Include="Debugging\FunctionInfo.cs" />
+ <Compile Include="Debugging\IDebugCallback.cs" />
+ <Compile Include="Debugging\InvokeTargets.cs" />
+ <Compile Include="Debugging\LambdaWalker.cs" />
+ <Compile Include="Debugging\Microsoft.Scripting.Debugging.Generated.cs" />
+ <Compile Include="Debugging\RuntimeOps.cs" />
+ <Compile Include="Debugging\RuntimeVariablesSupport\IDebugRuntimeVariables.cs" />
+ <Compile Include="Debugging\RuntimeVariablesSupport\IDebugThreadFactory.cs" />
+ <Compile Include="Debugging\ScopedRuntimeVariables.cs" />
+ <Compile Include="Debugging\ThreadLocal.cs" />
+ <Compile Include="Debugging\TraceEventKind.cs" />
+ <Compile Include="Debugging\TracePipeline\ITraceCallback.cs" />
+ <Compile Include="Debugging\TracePipeline\ITracePipeline.cs" />
+ <Compile Include="Debugging\TracePipeline\TracePipeline.cs" />
+ <Compile Include="Debugging\VariableInfo.cs" />
+ <Compile Include="Runtime\DynamicXamlReader.cs" />
+ <Compile Include="Runtime\LightThrowingAttribute.cs" />
+ <Compile Include="Ast\LightExceptionRewriter.cs" />
+ <Compile Include="Runtime\LightExceptions.cs" />
+ <Compile Include="Ast\SourceFileInformation.cs" />
+ <Compile Include="Ast\LightDynamicExpression.cs" />
+ <Compile Include="Ast\Utils.cs" />
+ <Compile Include="Ast\NewArrayExpression.cs" />
+ <Compile Include="Ast\NewExpression.cs" />
+ <Compile Include="Ast\UnaryExpression.cs" />
+ <Compile Include="ComInterop\ArgBuilder.cs" />
+ <Compile Include="ComInterop\BoolArgBuilder.cs" />
+ <Compile Include="ComInterop\BoundDispEvent.cs" />
+ <Compile Include="ComInterop\CollectionExtensions.cs" />
+ <Compile Include="ComInterop\ComBinder.cs" />
+ <Compile Include="ComInterop\ComBinderHelpers.cs" />
+ <Compile Include="ComInterop\ComClassMetaObject.cs" />
+ <Compile Include="ComInterop\ComDispIds.cs" />
+ <Compile Include="ComInterop\ComEventDesc.cs" />
+ <Compile Include="ComInterop\ComEventSink.cs" />
+ <Compile Include="ComInterop\ComEventSinkProxy.cs" />
+ <Compile Include="ComInterop\ComEventSinksContainer.cs" />
+ <Compile Include="ComInterop\ComFallbackMetaObject.cs" />
+ <Compile Include="ComInterop\ComHresults.cs" />
+ <Compile Include="ComInterop\ComInterop.cs" />
+ <Compile Include="ComInterop\ComInvokeAction.cs" />
+ <Compile Include="ComInterop\ComInvokeBinder.cs" />
+ <Compile Include="ComInterop\ComMetaObject.cs" />
+ <Compile Include="ComInterop\ComMethodDesc.cs" />
+ <Compile Include="ComInterop\ComObject.cs" />
+ <Compile Include="ComInterop\ComParamDesc.cs" />
+ <Compile Include="ComInterop\ComRuntimeHelpers.cs" />
+ <Compile Include="ComInterop\ComType.cs" />
+ <Compile Include="ComInterop\ComTypeClassDesc.cs" />
+ <Compile Include="ComInterop\ComTypeDesc.cs" />
+ <Compile Include="ComInterop\ComTypeEnumDesc.cs" />
+ <Compile Include="ComInterop\ComTypeLibDesc.cs" />
+ <Compile Include="ComInterop\ComTypeLibInfo.cs" />
+ <Compile Include="ComInterop\ComTypeLibMemberDesc.cs" />
+ <Compile Include="ComInterop\ConversionArgBuilder.cs" />
+ <Compile Include="ComInterop\ConvertArgBuilder.cs" />
+ <Compile Include="ComInterop\ConvertibleArgBuilder.cs" />
+ <Compile Include="ComInterop\CurrencyArgBuilder.cs" />
+ <Compile Include="ComInterop\DateTimeArgBuilder.cs" />
+ <Compile Include="ComInterop\DispatchArgBuilder.cs" />
+ <Compile Include="ComInterop\DispCallable.cs" />
+ <Compile Include="ComInterop\DispCallableMetaObject.cs" />
+ <Compile Include="ComInterop\ErrorArgBuilder.cs" />
+ <Compile Include="ComInterop\Errors.cs" />
+ <Compile Include="ComInterop\ExcepInfo.cs" />
+ <Compile Include="ComInterop\Helpers.cs" />
+ <Compile Include="ComInterop\IDispatchComObject.cs" />
+ <Compile Include="ComInterop\IDispatchMetaObject.cs" />
+ <Compile Include="ComInterop\IPseudoComObject.cs" />
+ <Compile Include="ComInterop\NullArgBuilder.cs" />
+ <Compile Include="ComInterop\SimpleArgBuilder.cs" />
+ <Compile Include="ComInterop\SplatCallSite.cs" />
+ <Compile Include="ComInterop\StringArgBuilder.cs" />
+ <Compile Include="ComInterop\TypeEnumMetaObject.cs" />
+ <Compile Include="ComInterop\TypeLibInfoMetaObject.cs" />
+ <Compile Include="ComInterop\TypeLibMetaObject.cs" />
+ <Compile Include="ComInterop\TypeUtils.cs" />
+ <Compile Include="ComInterop\UnknownArgBuilder.cs" />
+ <Compile Include="ComInterop\VarEnumSelector.cs" />
+ <Compile Include="ComInterop\Variant.cs" />
+ <Compile Include="ComInterop\VariantArgBuilder.cs" />
+ <Compile Include="ComInterop\VariantArray.cs" />
+ <Compile Include="ComInterop\VariantBuilder.cs" />
+ <Compile Include="Generation\FieldBuilderExpression.cs" />
+ <Compile Include="Hosting\Shell\ICommandDispatcher.cs" />
+ <Compile Include="Hosting\Shell\Remote\ConsoleRestartManager.cs" />
+ <Compile Include="Hosting\Shell\Remote\RemoteCommandDispatcher.cs" />
+ <Compile Include="Hosting\Shell\Remote\RemoteConsoleCommandLine.cs" />
+ <Compile Include="Hosting\Shell\Remote\RemoteConsoleHost.cs" />
+ <Compile Include="Hosting\Shell\Remote\RemoteRuntimeServer.cs" />
+ <Compile Include="Interpreter\BranchLabel.cs" />
+ <Compile Include="Interpreter\Instructions\AddInstruction.cs" />
+ <Compile Include="Interpreter\Instructions\ArrayOperations.cs" />
+ <Compile Include="Interpreter\Instructions\CallInstruction.cs" />
+ <Compile Include="Interpreter\Instructions\CallInstruction.Generated.cs" />
+ <Compile Include="Interpreter\Instructions\ControlFlowInstructions.cs" />
+ <Compile Include="Interpreter\Instructions\DivInstruction.cs" />
+ <Compile Include="Interpreter\Instructions\DynamicSplatInstruction.cs" />
+ <Compile Include="Interpreter\Instructions\EqualInstruction.cs" />
+ <Compile Include="Interpreter\Instructions\FieldOperations.cs" />
+ <Compile Include="Interpreter\Instructions\GreaterThanInstruction.cs" />
+ <Compile Include="Interpreter\Instructions\InstructionFactory.cs" />
+ <Compile Include="Interpreter\Instructions\LabelInfo.cs" />
+ <Compile Include="Interpreter\Instructions\LessThanInstruction.cs" />
+ <Compile Include="Interpreter\Instructions\LocalAccess.cs" />
+ <Compile Include="Interpreter\Instructions\InstructionList.cs" />
+ <Compile Include="Interpreter\Instructions\NotEqualInstruction.cs" />
+ <Compile Include="Interpreter\Instructions\NumericConvertInstruction.cs" />
+ <Compile Include="Interpreter\Instructions\StackOperations.cs" />
+ <Compile Include="Interpreter\Instructions\TypeOperations.cs" />
+ <Compile Include="Interpreter\ILightCallSiteBinder.cs" />
+ <Compile Include="Interpreter\LightDelegateCreator.cs" />
+ <Compile Include="Interpreter\LightLambda.Generated.cs" />
+ <Compile Include="Interpreter\Interpreter.cs" />
+ <Compile Include="Interpreter\Instructions\DynamicInstructions.Generated.cs" />
+ <Compile Include="Interpreter\Instructions\DynamicInstructionN.cs" />
+ <Compile Include="Interpreter\LightLambdaClosureVisitor.cs" />
+ <Compile Include="Interpreter\LightLambda.cs" />
+ <Compile Include="Interpreter\Instructions\Instruction.cs" />
+ <Compile Include="Interpreter\LightCompiler.cs" />
+ <Compile Include="Interpreter\LocalVariables.cs" />
+ <Compile Include="Interpreter\LoopCompiler.cs" />
+ <Compile Include="Interpreter\RuntimeVariables.cs" />
+ <Compile Include="Interpreter\InterpretedFrame.cs" />
+ <Compile Include="Math\BigIntegerV2.cs" />
+ <Compile Include="Math\BigIntegerV4.cs" />
+ <Compile Include="Runtime\ArgumentArray.cs" />
+ <Compile Include="Runtime\BindingRestrictionsHelpers.cs" />
+ <Compile Include="Runtime\DynamicDelegateCreator.cs" />
+ <Compile Include="Runtime\DynamicNull.cs" />
+ <Compile Include="Runtime\Generator.cs" />
+ <Compile Include="Ast\GeneratorExpression.cs" />
+ <Compile Include="Ast\GeneratorRewriter.cs" />
+ <Compile Include="Actions\Calls\Candidate.cs" />
+ <Compile Include="Ast\YieldExpression.cs" />
+ <Compile Include="Generation\DelegateHelpers.cs" />
+ <Compile Include="Generation\DelegateHelpers.Generated.cs" />
+ <Compile Include="Generation\AssemblyGen.cs" />
+ <Compile Include="Generation\ConstantCheck.cs" />
+ <Compile Include="Generation\DynamicILGen.cs" />
+ <Compile Include="Generation\ILGen.cs" />
+ <Compile Include="Generation\KeyedQueue.cs" />
+ <Compile Include="Generation\Snippets.cs" />
+ <Compile Include="Generation\TypeGen.cs" />
+ <Compile Include="Actions\ComboActionRewriter.cs" />
+ <Compile Include="Actions\ComboBinder.cs" />
+ <Compile Include="Actions\ConditionalBuilder.cs" />
+ <Compile Include="Actions\DefaultBinder.Conversions.cs" />
+ <Compile Include="Actions\DefaultBinder.DeleteMember.cs" />
+ <Compile Include="Actions\DefaultBinder.GetMember.cs" />
+ <Compile Include="Actions\DefaultBinder.Invoke.cs" />
+ <Compile Include="Actions\DefaultBinder.MethodCalls.cs" />
+ <Compile Include="Actions\DefaultBinder.SetMember.cs" />
+ <Compile Include="Actions\DefaultBinder.cs" />
+ <Compile Include="Actions\NoSideEffectsAttribute.cs" />
+ <Compile Include="Actions\OperatorInfo.cs" />
+ <Compile Include="Ast\BinaryExpression.cs" />
+ <Compile Include="Ast\Block.cs" />
+ <Compile Include="Ast\ConstantExpression.cs" />
+ <Compile Include="Ast\EmptyStatements.cs" />
+ <Compile Include="Ast\LambdaBuilder.cs" />
+ <Compile Include="Ast\LambdaParameterRewriter.cs" />
+ <Compile Include="Ast\LoopStatement.cs" />
+ <Compile Include="Ast\MethodCallExpression.cs" />
+ <Compile Include="Ast\TryStatementBuilder.cs" />
+ <Compile Include="MultiRuntimeAwareAttribute.cs" />
+ <Compile Include="PerfTrack.cs" />
+ <Compile Include="Runtime\CompilerContext.cs" />
+ <Compile Include="Runtime\DynamicLanguageProviderAttribute.cs" />
+ <Compile Include="Runtime\IConvertibleMetaObject.cs" />
+ <Compile Include="Runtime\ICustomScriptCodeData.cs" />
+ <Compile Include="Runtime\IRestrictedMetaObject.cs" />
+ <Compile Include="Runtime\LegacyScriptCode.cs" />
+ <Compile Include="Runtime\MetaObjectExtensions.cs" />
+ <Compile Include="Runtime\RestrictedMetaObject.cs" />
+ <Compile Include="Runtime\SavableScriptCode.cs" />
+ <Compile Include="Runtime\TokenizerBuffer.cs" />
+ <Compile Include="Generation\MethodSignatureInfo.cs" />
+ <Compile Include="Hosting\Shell\BasicConsole.cs" />
+ <Compile Include="Hosting\Shell\CommandLine.cs" />
+ <Compile Include="Hosting\Shell\ConsoleHost.cs" />
+ <Compile Include="Hosting\Shell\ConsoleHostOptions.cs" />
+ <Compile Include="Hosting\Shell\ConsoleHostOptionsParser.cs" />
+ <Compile Include="Hosting\Shell\ConsoleOptions.cs" />
+ <Compile Include="Hosting\Shell\IConsole.cs" />
+ <Compile Include="Hosting\Shell\OptionsParser.cs" />
+ <Compile Include="Hosting\Shell\Style.cs" />
+ <Compile Include="Hosting\Shell\SuperConsole.cs" />
+ <Compile Include="GlobalSuppressions.cs" />
+ <Compile Include="Math\Complex64.cs" />
+ <Compile Include="Properties\AssemblyInfo.cs" />
+ <Compile Include="Runtime\AmbiguousFileNameException.cs" />
+ <Compile Include="Runtime\BinderOps.cs" />
+ <Compile Include="Runtime\CallTypes.cs" />
+ <Compile Include="Runtime\Cast.Generated.cs" />
+ <Compile Include="Runtime\Cast.cs" />
+ <Compile Include="Runtime\CodeDomCodeGen.cs" />
+ <Compile Include="Runtime\DelegateInfo.cs" />
+ <Compile Include="Runtime\DelegateSignatureInfo.cs" />
+ <Compile Include="Runtime\ISlice.cs" />
+ <Compile Include="Runtime\IdDispenser.cs" />
+ <Compile Include="Runtime\LanguageBoundTextContentProvider.cs" />
+ <Compile Include="Runtime\LocalsDictionary.cs" />
+ <Compile Include="Runtime\PositionTrackingWriter.cs" />
+ <Compile Include="Runtime\ReturnFixer.cs" />
+ <Compile Include="Runtime\SourceStringContentProvider.cs" />
+ <Compile Include="Utils\CacheDict.cs" />
+ <Compile Include="Utils\CollectionExtensions.cs" />
+ <Compile Include="Utils\CopyOnWriteList.cs" />
+ <Compile Include="Utils\DynamicUtils.cs" />
+ <Compile Include="Utils\EnumUtils.cs" />
+ <Compile Include="Utils\HybridReferenceDictionary.cs" />
+ <Compile Include="Utils\ListEqualityComparer.cs" />
+ <Compile Include="Utils\MathUtils.cs" />
+ <Compile Include="Utils\MonitorUtils.cs" />
+ <Compile Include="Utils\Publisher.cs" />
+ <Compile Include="Utils\ReadOnlyDictionary.cs" />
+ <Compile Include="Utils\ReferenceEqualityComparer.cs" />
+ <Compile Include="Utils\HashSet.cs" />
+ <Compile Include="Utils\SynchronizedDictionary.cs" />
+ <Compile Include="Utils\ThreadLocal.cs" />
+ <Compile Include="Utils\TypeUtils.cs" />
+ <Compile Include="Utils\ValueArray.cs" />
+ <Compile Include="Utils\WeakCollection.cs" />
+ <Compile Include="Utils\WeakDictionary.cs" />
+ <Compile Include="Utils\WeakHandle.cs" />
+ <Compile Include="DebugOptions.cs" />
+ <Compile Include="SpecSharp.cs" />
+ <Compile Include="MutableTuple.cs" />
+ <Compile Include="Actions\ActionBinder.cs" />
+ <Compile Include="Actions\Argument.cs" />
+ <Compile Include="Actions\ArgumentType.cs" />
+ <Compile Include="Actions\BoundMemberTracker.cs" />
+ <Compile Include="Actions\CallSignature.cs" />
+ <Compile Include="Actions\ConstructorTracker.cs" />
+ <Compile Include="Actions\CustomTracker.cs" />
+ <Compile Include="Actions\ErrorInfo.cs" />
+ <Compile Include="Actions\EventTracker.cs" />
+ <Compile Include="Actions\ExtensionMethodTracker.cs" />
+ <Compile Include="Actions\ExtensionPropertyTracker.cs" />
+ <Compile Include="Actions\FieldTracker.cs" />
+ <Compile Include="Actions\MemberGroup.cs" />
+ <Compile Include="Actions\MemberTracker.cs" />
+ <Compile Include="Actions\MethodGroup.cs" />
+ <Compile Include="Actions\MethodTracker.cs" />
+ <Compile Include="Actions\NamespaceTracker.cs" />
+ <Compile Include="Actions\NestedTypeTracker.cs" />
+ <Compile Include="Actions\PropertyTracker.cs" />
+ <Compile Include="Actions\ReflectedPropertyTracker.cs" />
+ <Compile Include="Actions\TopNamespaceTracker.cs" />
+ <Compile Include="Actions\TrackerTypes.cs" />
+ <Compile Include="Actions\TypeGroup.cs" />
+ <Compile Include="Actions\TypeTracker.cs" />
+ <Compile Include="Ast\DebugStatement.cs" />
+ <Compile Include="Ast\IfStatementBuilder.cs" />
+ <Compile Include="Ast\IfStatementTest.cs" />
+ <Compile Include="Generation\CompilerHelpers.cs" />
+ <Compile Include="Generation\IExpressionSerializable.cs" />
+ <Compile Include="Generation\ToDiskRewriter.cs" />
+ <Compile Include="Runtime\AssemblyTypeNames.cs" />
+ <Compile Include="Runtime\BinderType.cs" />
+ <Compile Include="Runtime\CallTargets.cs" />
+ <Compile Include="Runtime\CustomStringDictionary.cs" />
+ <Compile Include="Runtime\DlrCachedCodeAttribute.cs" />
+ <Compile Include="Runtime\DocumentationAttribute.cs" />
+ <Compile Include="Runtime\ExceptionHelpers.cs" />
+ <Compile Include="Runtime\ExplicitConversionMethodAttribute.cs" />
+ <Compile Include="Runtime\Extensible.cs" />
+ <Compile Include="Runtime\ExtensionTypeAttribute.cs" />
+ <Compile Include="Runtime\ExtraKeyEnumerator.cs" />
+ <Compile Include="Runtime\IMembersList.cs" />
+ <Compile Include="Runtime\ImplicitConversionMethodAttribute.cs" />
+ <Compile Include="Runtime\ModuleChangeEventArgs.cs" />
+ <Compile Include="Runtime\ModuleChangeEventType.cs" />
+ <Compile Include="Runtime\NullTextContentProvider.cs" />
+ <Compile Include="Runtime\OperationFailed.cs" />
+ <Compile Include="Runtime\OperatorSlotAttribute.cs" />
+ <Compile Include="Runtime\PropertyMethodAttribute.cs" />
+ <Compile Include="Runtime\ReflectionCache.cs" />
+ <Compile Include="Runtime\ScriptingRuntimeHelpers.cs" />
+ <Compile Include="Runtime\StaticExtensionMethodAttribute.cs" />
+ <Compile Include="Runtime\Uninitialized.cs" />
+ <Compile Include="Utils\ArrayUtils.cs" />
+ <Compile Include="Utils\AssemblyQualifiedTypeName.cs" />
+ <Compile Include="Utils\Assert.cs" />
+ <Compile Include="Utils\CheckedDictionaryEnumerator.cs" />
+ <Compile Include="Utils\CollectionUtils.cs" />
+ <Compile Include="Utils\ContractUtils.cs" />
+ <Compile Include="Utils\DictionaryUnionEnumerator.cs" />
+ <Compile Include="Utils\ExceptionFactory.Generated.cs" />
+ <Compile Include="Utils\ExceptionUtils.cs" />
+ <Compile Include="Utils\IOUtils.cs" />
+ <Compile Include="Utils\ReflectionUtils.cs" />
+ <Compile Include="Utils\StringUtils.cs" />
+ <Compile Include="Utils\TextStream.cs" />
+ <Compile Include="IValueEquality.cs" />
+ <Compile Include="KeyboardInterruptException.cs" />
+ <Compile Include="SourceFileContentProvider.cs" />
+ </ItemGroup>
+ <ItemGroup Condition=" '$(SilverlightBuild)' != 'true' ">
+ <Reference Include="System" />
+ <Reference Include="System.Xml" />
+ <Reference Include="System.Configuration" />
+ <Reference Include="System.Numerics" Condition=" '$(TargetFrameworkVersion)' == 'v4.0' " />
+ <Reference Include="System.Core" />
+ <Reference Include="System.Data" />
+ <Reference Include="System.Runtime.Remoting" />
+ <Reference Include="System.Xaml" Condition="'$(TargetFrameworkVersion)' == 'v4.0'" />
+ </ItemGroup>
+ <ItemGroup Condition=" '$(SilverlightBuild)' == 'true' ">
+ <Reference Include="mscorlib, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e">
+ <SpecificVersion>False</SpecificVersion>
+ <HintPath>$(SilverlightPath)\mscorlib.dll</HintPath>
+ </Reference>
+ <Reference Include="System, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e">
+ <SpecificVersion>False</SpecificVersion>
+ <HintPath>$(SilverlightPath)\System.dll</HintPath>
+ </Reference>
+ <Reference Include="System.Core, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e">
+ <SpecificVersion>False</SpecificVersion>
+ <HintPath>$(SilverlightPath)\System.Core.dll</HintPath>
+ </Reference>
+ <Reference Include="System.Numerics, Version=2.0.5.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" Condition="'$(TargetFrameworkVersion)' == 'v4.0' ">
+ <SpecificVersion>False</SpecificVersion>
+ <HintPath>$(SilverlightPath)\System.Numerics.dll</HintPath>
+ </Reference>
+ </ItemGroup>
+ <ItemGroup>
+ <ProjectReference Include="..\Microsoft.Scripting.Core\Microsoft.Scripting.Core.csproj" Condition="'$(TargetFrameworkVersion)' != 'v4.0'">
+ <Project>{2AE75F5A-CD1F-4925-9647-AF4D1C282FB4}</Project>
+ <Name>Microsoft.Scripting.Core</Name>
+ <Private>False</Private>
+ </ProjectReference>
+ <ProjectReference Include="..\Microsoft.Scripting\Microsoft.Scripting.csproj">
+ <Project>{02FF0909-F5AD-48CF-A86A-345E721B7E40}</Project>
+ <Name>Microsoft.Scripting</Name>
+ </ProjectReference>
+ <ProjectReference Include="..\Microsoft.Scripting.Metadata\Microsoft.Scripting.Metadata.csproj" Condition=" '$(SilverlightBuild)' != 'true' ">
+ <Project>{ACDD9B9E-8FE6-439C-9521-1CCBA47F6143}</Project>
+ <Name>Microsoft.Scripting.Metadata</Name>
+ </ProjectReference>
+ </ItemGroup>
+ <ItemGroup>
+ <Content Include="Microsoft.Scripting.txt" />
+ </ItemGroup>
+ <ItemGroup>
+ <None Include="Microsoft.Dynamic.ruleset" />
+ </ItemGroup>
+ <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" Condition=" '$(SilverlightTreeBuild)' != 'true' " />
+</Project>
diff --git a/mcs/class/dlr/Runtime/Microsoft.Dynamic/Properties/AssemblyInfo.cs b/mcs/class/dlr/Runtime/Microsoft.Dynamic/Properties/AssemblyInfo.cs index a15dcb547c7..1d07e6bce67 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Dynamic/Properties/AssemblyInfo.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Dynamic/Properties/AssemblyInfo.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -28,7 +28,7 @@ using System.Security.Permissions; [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("Microsoft")] [assembly: AssemblyProduct("Microsoft.Scripting")] -[assembly: AssemblyCopyright("� Microsoft Corporation. All rights reserved.")] +[assembly: AssemblyCopyright("© Microsoft Corporation. All rights reserved.")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] @@ -51,21 +51,23 @@ using System.Security.Permissions; // // You can specify all the values or you can default the Revision and Build Numbers // by using the '*' as shown below: -[assembly: SecurityTransparent] #if !CLR2 && !SILVERLIGHT [assembly: SecurityRules(SecurityRuleSet.Level1)] #endif +[assembly: SecurityTransparent] [assembly: System.Resources.NeutralResourcesLanguage("en-US")] #if SIGNED +[assembly: InternalsVisibleTo("TestInternalDLR, PublicKey=0024000004800000940000000602000000240000525341310004000001000100b5fc90e7027f67871e773a8fde8938c81dd402ba65b9201d60593e96c492651e889cc13f1415ebb53fac1131ae0bd333c5ee6021672d9718ea31a8aebd0da0072f25d87dba6fc90ffd598ed4da35e44c398c454307e8e33b8426143daec9f596836f97c8f74750e5975c64e2189f45def46b2a2b1247adc3652bf5c308055da9")] #else +[assembly: InternalsVisibleTo("TestInternalDLR")] #endif #if !SILVERLIGHT -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.1.00")] -[assembly: AssemblyInformationalVersion("1.0.1")] +[assembly: AssemblyVersion("1.1.0.10")] +[assembly: AssemblyFileVersion("1.1.0.10")] +[assembly: AssemblyInformationalVersion("1.1")] [assembly: AllowPartiallyTrustedCallers] [assembly: TypeForwardedTo(typeof(Microsoft.Scripting.Runtime.DynamicStackFrame))] #endif diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/BinaryOperationBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/BinaryOperationBinder.cs index 079e768a9ff..0b55a9e2cd5 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/BinaryOperationBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/BinaryOperationBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/BindingRestrictions.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/BindingRestrictions.cs index 6a523218230..2b1115cb49c 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/BindingRestrictions.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/BindingRestrictions.cs @@ -2,11 +2,11 @@ *
* Copyright (c) Microsoft Corporation.
*
- * This source code is subject to terms and conditions of the Microsoft Public License. A
+ * This source code is subject to terms and conditions of the Apache License, Version 2.0. A
* copy of the license can be found in the License.html file at the root of this distribution. If
- * you cannot locate the Microsoft Public License, please send an email to
+ * you cannot locate the Apache License, Version 2.0, please send an email to
* dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound
- * by the terms of the Microsoft Public License.
+ * by the terms of the Apache License, Version 2.0.
*
* You must not remove this notice, or any other, from this software.
*
diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallInfo.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallInfo.cs index d3fc9c95b1e..0bb62542ac6 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallInfo.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallInfo.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSite.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSite.cs index c02928faaf3..9dd1f34e65f 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSite.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSite.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -99,7 +99,7 @@ namespace System.Runtime.CompilerServices { public static CallSite Create(Type delegateType, CallSiteBinder binder) { ContractUtils.RequiresNotNull(delegateType, "delegateType"); ContractUtils.RequiresNotNull(binder, "binder"); - if (!delegateType.IsSubclassOf(typeof(Delegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); + if (!delegateType.IsSubclassOf(typeof(MulticastDelegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); if (_SiteCtors == null) { // It's okay to just set this, worst case we're just throwing away some data @@ -132,7 +132,7 @@ namespace System.Runtime.CompilerServices { /// Dynamic site type. /// </summary> /// <typeparam name="T">The delegate type.</typeparam> - public sealed partial class CallSite<T> : CallSite where T : class { + public partial class CallSite<T> : CallSite where T : class { /// <summary> /// The update delegate. Called when the dynamic site experiences cache miss. /// </summary> @@ -191,6 +191,7 @@ namespace System.Runtime.CompilerServices { /// <returns>The new instance of dynamic call site.</returns> [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1000:DoNotDeclareStaticMembersOnGenericTypes")] public static CallSite<T> Create(CallSiteBinder binder) { + if (!typeof(T).IsSubclassOf(typeof(MulticastDelegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); return new CallSite<T>(binder); } @@ -279,8 +280,8 @@ namespace System.Runtime.CompilerServices { } } if (method != null) { - _CachedNoMatch = (T)(object)noMatchMethod.MakeGenericMethod(args).CreateDelegate(target); - return (T)(object)method.MakeGenericMethod(args).CreateDelegate(target); + _CachedNoMatch = (T)(object)CreateDelegateHelper(target, noMatchMethod.MakeGenericMethod(args)); + return (T)(object)CreateDelegateHelper(target, method.MakeGenericMethod(args)); } } @@ -288,6 +289,28 @@ namespace System.Runtime.CompilerServices { return CreateCustomUpdateDelegate(invoke); } + // NEEDS SECURITY REVIEW: + // + // This needs to be SafeCritical on Silverlight to allow access to + // internal types from user code as generic parameters. + // + // It's safe for a few reasons: + // 1. The internal types are coming from a lower trust level (app code) + // 2. We got the internal types from our own generic parameter: T + // 3. The UpdateAndExecute methods don't do anything with the types, + // we just want the CallSite args to be strongly typed to avoid + // casting. + // 4. Works on desktop CLR with AppDomain that has only Execute + // permission. In theory it might require RestrictedMemberAccess, + // but it's unclear because we have tests passing without RMA. + // + // When Silverlight gets RMA we may be able to remove this. +#if SILVERLIGHT + [System.Security.SecuritySafeCritical] +#endif + private static Delegate CreateDelegateHelper(Type delegateType, MethodInfo method) { + return Delegate.CreateDelegate(delegateType, method); + } private static bool IsSimpleSignature(MethodInfo invoke, out Type[] sig) { ParameterInfo[] pis = invoke.GetParametersCached(); @@ -314,7 +337,6 @@ namespace System.Runtime.CompilerServices { [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Performance", "CA1822:MarkMembersAsStatic")] private T CreateCustomNoMatchDelegate(MethodInfo invoke) { var @params = invoke.GetParametersCached().Map(p => Expression.Parameter(p.ParameterType, p.Name)); - var site = @params[0]; return Expression.Lambda<T>( Expression.Block( Expression.Call( diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSiteBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSiteBinder.cs index f275a2b7966..03fb5d15a90 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSiteBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSiteBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -66,7 +66,7 @@ namespace System.Runtime.CompilerServices { private LambdaSignature() { Type target = typeof(T); - if (!typeof(Delegate).IsAssignableFrom(target)) { + if (!target.IsSubclassOf(typeof(MulticastDelegate))) { throw Error.TypeParameterIsNotDelegate(target); } @@ -166,7 +166,6 @@ namespace System.Runtime.CompilerServices { } private static Expression<T> Stitch<T>(Expression binding, LambdaSignature<T> signature) where T : class { - Type targetType = typeof(T); Type siteType = typeof(CallSite<T>); var body = new ReadOnlyCollectionBuilder<Expression>(3); diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSiteHelpers.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSiteHelpers.cs index 48f52e8a30c..38e177d1546 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSiteHelpers.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSiteHelpers.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSiteOps.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSiteOps.cs index 6b72589d65e..f13a29b0fc0 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSiteOps.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CallSiteOps.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/ConvertBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/ConvertBinder.cs index e8ca9b866ff..af6b2782502 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/ConvertBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/ConvertBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CreateInstanceBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CreateInstanceBinder.cs index bb18e4ca731..9edf1b7db0e 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CreateInstanceBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/CreateInstanceBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DeleteIndexBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DeleteIndexBinder.cs index 6c38caa1e4c..e2523a5d0e5 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DeleteIndexBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DeleteIndexBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DeleteMemberBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DeleteMemberBinder.cs index 02881df6949..d01bfcdf00b 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DeleteMemberBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DeleteMemberBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DynamicMetaObject.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DynamicMetaObject.cs index 8d28b9dd04d..96ffe2aecda 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DynamicMetaObject.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DynamicMetaObject.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DynamicMetaObjectBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DynamicMetaObjectBinder.cs index 0289de8c4ce..7aece9c5a03 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DynamicMetaObjectBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DynamicMetaObjectBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DynamicObject.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DynamicObject.cs index 8c00a873151..5d0bdf6c83a 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DynamicObject.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/DynamicObject.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -22,6 +22,7 @@ using System.Linq.Expressions; using System.Diagnostics; using System.Dynamic.Utils; using System.Reflection; +using System.Runtime.CompilerServices; namespace System.Dynamic { /// <summary> @@ -32,6 +33,7 @@ namespace System.Dynamic { /// If a method is not overridden then the DynamicObject does not directly support that behavior and /// the call site will determine how the binding should be performed. /// </summary> + [Serializable] public class DynamicObject : IDynamicMetaObjectProvider { /// <summary> @@ -242,7 +244,7 @@ namespace System.Dynamic { public override DynamicMetaObject BindSetMember(SetMemberBinder binder, DynamicMetaObject value) { if (IsOverridden("TrySetMember")) { - return CallMethodReturnLast("TrySetMember", binder, GetArgs(value), (e) => binder.FallbackSetMember(this, value, e)); + return CallMethodReturnLast("TrySetMember", binder, NoArgs, value.Expression, (e) => binder.FallbackSetMember(this, value, e)); } return base.BindSetMember(binder, value); @@ -285,7 +287,7 @@ namespace System.Dynamic { var call = BuildCallMethodWithResult( "TryInvokeMember", binder, - GetArgArray(args), + DynamicMetaObject.GetExpressions(args), BuildCallMethodWithResult( "TryGetMember", new GetBinderAdapter(binder), @@ -302,7 +304,7 @@ namespace System.Dynamic { public override DynamicMetaObject BindCreateInstance(CreateInstanceBinder binder, DynamicMetaObject[] args) { if (IsOverridden("TryCreateInstance")) { - return CallMethodWithResult("TryCreateInstance", binder, GetArgArray(args), (e) => binder.FallbackCreateInstance(this, args, e)); + return CallMethodWithResult("TryCreateInstance", binder, DynamicMetaObject.GetExpressions(args), (e) => binder.FallbackCreateInstance(this, args, e)); } return base.BindCreateInstance(binder, args); @@ -310,7 +312,7 @@ namespace System.Dynamic { public override DynamicMetaObject BindInvoke(InvokeBinder binder, DynamicMetaObject[] args) { if (IsOverridden("TryInvoke")) { - return CallMethodWithResult("TryInvoke", binder, GetArgArray(args), (e) => binder.FallbackInvoke(this, args, e)); + return CallMethodWithResult("TryInvoke", binder, DynamicMetaObject.GetExpressions(args), (e) => binder.FallbackInvoke(this, args, e)); } return base.BindInvoke(binder, args); @@ -318,7 +320,7 @@ namespace System.Dynamic { public override DynamicMetaObject BindBinaryOperation(BinaryOperationBinder binder, DynamicMetaObject arg) { if (IsOverridden("TryBinaryOperation")) { - return CallMethodWithResult("TryBinaryOperation", binder, GetArgs(arg), (e) => binder.FallbackBinaryOperation(this, arg, e)); + return CallMethodWithResult("TryBinaryOperation", binder, DynamicMetaObject.GetExpressions(new DynamicMetaObject[] {arg}), (e) => binder.FallbackBinaryOperation(this, arg, e)); } return base.BindBinaryOperation(binder, arg); @@ -334,7 +336,7 @@ namespace System.Dynamic { public override DynamicMetaObject BindGetIndex(GetIndexBinder binder, DynamicMetaObject[] indexes) { if (IsOverridden("TryGetIndex")) { - return CallMethodWithResult("TryGetIndex", binder, GetArgArray(indexes), (e) => binder.FallbackGetIndex(this, indexes, e)); + return CallMethodWithResult("TryGetIndex", binder, DynamicMetaObject.GetExpressions(indexes), (e) => binder.FallbackGetIndex(this, indexes, e)); } return base.BindGetIndex(binder, indexes); @@ -342,7 +344,7 @@ namespace System.Dynamic { public override DynamicMetaObject BindSetIndex(SetIndexBinder binder, DynamicMetaObject[] indexes, DynamicMetaObject value) { if (IsOverridden("TrySetIndex")) { - return CallMethodReturnLast("TrySetIndex", binder, GetArgArray(indexes, value), (e) => binder.FallbackSetIndex(this, indexes, value, e)); + return CallMethodReturnLast("TrySetIndex", binder, DynamicMetaObject.GetExpressions(indexes), value.Expression, (e) => binder.FallbackSetIndex(this, indexes, value, e)); } return base.BindSetIndex(binder, indexes, value); @@ -350,7 +352,7 @@ namespace System.Dynamic { public override DynamicMetaObject BindDeleteIndex(DeleteIndexBinder binder, DynamicMetaObject[] indexes) { if (IsOverridden("TryDeleteIndex")) { - return CallMethodNoResult("TryDeleteIndex", binder, GetArgArray(indexes), (e) => binder.FallbackDeleteIndex(this, indexes, e)); + return CallMethodNoResult("TryDeleteIndex", binder, DynamicMetaObject.GetExpressions(indexes), (e) => binder.FallbackDeleteIndex(this, indexes, e)); } return base.BindDeleteIndex(binder, indexes); @@ -360,25 +362,61 @@ namespace System.Dynamic { private readonly static Expression[] NoArgs = new Expression[0]; - private static Expression[] GetArgs(params DynamicMetaObject[] args) { - Expression[] paramArgs = DynamicMetaObject.GetExpressions(args); + private static Expression[] GetConvertedArgs(params Expression[] args) { + ReadOnlyCollectionBuilder<Expression> paramArgs = new ReadOnlyCollectionBuilder<Expression>(args.Length); - for (int i = 0; i < paramArgs.Length; i++) { - paramArgs[i] = Expression.Convert(args[i].Expression, typeof(object)); + for (int i = 0; i < args.Length; i++) { + paramArgs.Add(Expression.Convert(args[i], typeof(object))); } - return paramArgs; + return paramArgs.ToArray(); } - private static Expression[] GetArgArray(DynamicMetaObject[] args) { - return new[] { Expression.NewArrayInit(typeof(object), GetArgs(args)) }; + /// <summary> + /// Helper method for generating expressions that assign byRef call + /// parameters back to their original variables + /// </summary> + private static Expression ReferenceArgAssign(Expression callArgs, Expression[] args) { + ReadOnlyCollectionBuilder<Expression> block = null; + + for (int i = 0; i < args.Length; i++) { + ContractUtils.Requires(args[i] is ParameterExpression); + if (((ParameterExpression)args[i]).IsByRef) { + if (block == null) + block = new ReadOnlyCollectionBuilder<Expression>(); + + block.Add( + Expression.Assign( + args[i], + Expression.Convert( + Expression.ArrayIndex( + callArgs, + Expression.Constant(i) + ), + args[i].Type + ) + ) + ); + } + } + + if (block != null) + return Expression.Block(block); + else + return Expression.Empty(); } - private static Expression[] GetArgArray(DynamicMetaObject[] args, DynamicMetaObject value) { - return new Expression[] { - Expression.NewArrayInit(typeof(object), GetArgs(args)), - Expression.Convert(value.Expression, typeof(object)) - }; + /// <summary> + /// Helper method for generating arguments for calling methods + /// on DynamicObject. parameters is either a list of ParameterExpressions + /// to be passed to the method as an object[], or NoArgs to signify that + /// the target method takes no object[] parameter. + /// </summary> + private static Expression[] BuildCallArgs(DynamicMetaObjectBinder binder, Expression[] parameters, Expression arg0, Expression arg1) { + if (!object.ReferenceEquals(parameters, NoArgs)) + return arg1 != null ? new Expression[] { Constant(binder), arg0, arg1 } : new Expression[] { Constant(binder), arg0 }; + else + return arg1 != null ? new Expression[] { Constant(binder), arg1 } : new Expression[] { Constant(binder) }; } private static ConstantExpression Constant(DynamicMetaObjectBinder binder) { @@ -421,6 +459,14 @@ namespace System.Dynamic { return fallback(callDynamic); } + /// <summary> + /// Helper method for generating a MetaObject which calls a + /// specific method on DynamicObject that returns a result. + /// + /// args is either an array of arguments to be passed + /// to the method as an object[] or NoArgs to signify that + /// the target method takes no parameters. + /// </summary> private DynamicMetaObject BuildCallMethodWithResult(string methodName, DynamicMetaObjectBinder binder, Expression[] args, DynamicMetaObject fallbackResult, Fallback fallbackInvoke) { if (!IsOverridden(methodName)) { return fallbackResult; @@ -434,11 +480,8 @@ namespace System.Dynamic { // } // var result = Expression.Parameter(typeof(object), null); - - var callArgs = new Expression[args.Length + 2]; - Array.Copy(args, 0, callArgs, 1, args.Length); - callArgs[0] = Constant(binder); - callArgs[callArgs.Length - 1] = result; + ParameterExpression callArgs = methodName != "TryBinaryOperation" ? Expression.Parameter(typeof(object[]), null) : Expression.Parameter(typeof(object), null); + var callArgsValue = GetConvertedArgs(args); var resultMO = new DynamicMetaObject(result, BindingRestrictions.Empty); @@ -450,7 +493,39 @@ namespace System.Dynamic { // will always be a cast or unbox Debug.Assert(convert.Method == null); - resultMO = new DynamicMetaObject(convert, resultMO.Restrictions); + // Prepare a good exception message in case the convert will fail + string convertFailed = Strings.DynamicObjectResultNotAssignable( + "{0}", + this.Value.GetType(), + binder.GetType(), + binder.ReturnType + ); + + var checkedConvert = Expression.Condition( + Expression.TypeIs(resultMO.Expression, binder.ReturnType), + convert, + Expression.Throw( + Expression.New(typeof(InvalidCastException).GetConstructor(new Type[]{typeof(string)}), + Expression.Call( + typeof(string).GetMethod("Format", new Type[] {typeof(string), typeof(object)}), + Expression.Constant(convertFailed), + Expression.Condition( + Expression.Equal(resultMO.Expression, Expression.Constant(null)), + Expression.Constant("null"), + Expression.Call( + resultMO.Expression, + typeof(object).GetMethod("GetType") + ), + typeof(object) + ) + ) + ), + binder.ReturnType + ), + binder.ReturnType + ); + + resultMO = new DynamicMetaObject(checkedConvert, resultMO.Restrictions); } if (fallbackInvoke != null) { @@ -459,14 +534,23 @@ namespace System.Dynamic { var callDynamic = new DynamicMetaObject( Expression.Block( - new[] { result }, + new[] { result, callArgs }, + methodName != "TryBinaryOperation" ? Expression.Assign(callArgs, Expression.NewArrayInit(typeof(object), callArgsValue)) : Expression.Assign(callArgs, callArgsValue[0]), Expression.Condition( Expression.Call( GetLimitedSelf(), typeof(DynamicObject).GetMethod(methodName), - callArgs + BuildCallArgs( + binder, + args, + callArgs, + result + ) + ), + Expression.Block( + methodName != "TryBinaryOperation" ? ReferenceArgAssign(callArgs, args) : Expression.Empty(), + resultMO.Expression ), - resultMO.Expression, fallbackResult.Expression, binder.ReturnType ) @@ -481,8 +565,12 @@ namespace System.Dynamic { /// Helper method for generating a MetaObject which calls a /// specific method on Dynamic, but uses one of the arguments for /// the result. + /// + /// args is either an array of arguments to be passed + /// to the method as an object[] or NoArgs to signify that + /// the target method takes no parameters. /// </summary> - private DynamicMetaObject CallMethodReturnLast(string methodName, DynamicMetaObjectBinder binder, Expression[] args, Fallback fallback) { + private DynamicMetaObject CallMethodReturnLast(string methodName, DynamicMetaObjectBinder binder, Expression[] args, Expression value, Fallback fallback) { // // First, call fallback to do default binding // This produces either an error or a call to a .NET member @@ -498,19 +586,28 @@ namespace System.Dynamic { // var result = Expression.Parameter(typeof(object), null); - var callArgs = args.AddFirst(Constant(binder)); - callArgs[args.Length] = Expression.Assign(result, callArgs[args.Length]); + var callArgs = Expression.Parameter(typeof(object[]), null); + var callArgsValue = GetConvertedArgs(args); var callDynamic = new DynamicMetaObject( Expression.Block( - new[] { result }, + new[] { result, callArgs }, + Expression.Assign(callArgs, Expression.NewArrayInit(typeof(object), callArgsValue)), Expression.Condition( Expression.Call( GetLimitedSelf(), typeof(DynamicObject).GetMethod(methodName), - callArgs + BuildCallArgs( + binder, + args, + callArgs, + Expression.Assign(result, Expression.Convert(value, typeof(object))) + ) + ), + Expression.Block( + ReferenceArgAssign(callArgs, args), + result ), - result, fallbackResult.Expression, typeof(object) ) @@ -534,6 +631,10 @@ namespace System.Dynamic { /// Helper method for generating a MetaObject which calls a /// specific method on Dynamic, but uses one of the arguments for /// the result. + /// + /// args is either an array of arguments to be passed + /// to the method as an object[] or NoArgs to signify that + /// the target method takes no parameters. /// </summary> private DynamicMetaObject CallMethodNoResult(string methodName, DynamicMetaObjectBinder binder, Expression[] args, Fallback fallback) { // @@ -541,21 +642,35 @@ namespace System.Dynamic { // This produces either an error or a call to a .NET member // DynamicMetaObject fallbackResult = fallback(null); + var callArgs = Expression.Parameter(typeof(object[]), null); + var callArgsValue = GetConvertedArgs(args); // // Build a new expression like: // if (TryDeleteMember(payload)) { } else { fallbackResult } // var callDynamic = new DynamicMetaObject( - Expression.Condition( - Expression.Call( - GetLimitedSelf(), - typeof(DynamicObject).GetMethod(methodName), - args.AddFirst(Constant(binder)) - ), - Expression.Empty(), - fallbackResult.Expression, - typeof(void) + Expression.Block( + new[] { callArgs }, + Expression.Assign(callArgs, Expression.NewArrayInit(typeof(object), callArgsValue)), + Expression.Condition( + Expression.Call( + GetLimitedSelf(), + typeof(DynamicObject).GetMethod(methodName), + BuildCallArgs( + binder, + args, + callArgs, + null + ) + ), + Expression.Block( + ReferenceArgAssign(callArgs, args), + Expression.Empty() + ), + fallbackResult.Expression, + typeof(void) + ) ), GetRestrictions().Merge(fallbackResult.Restrictions) ); diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/ExpandoClass.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/ExpandoClass.cs index 6122329640d..8e8afbe4d67 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/ExpandoClass.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/ExpandoClass.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/ExpandoObject.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/ExpandoObject.cs index c2d73e91853..6ba7c7d510b 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/ExpandoObject.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/ExpandoObject.cs @@ -2,11 +2,11 @@ *
* Copyright (c) Microsoft Corporation.
*
- * This source code is subject to terms and conditions of the Microsoft Public License. A
+ * This source code is subject to terms and conditions of the Apache License, Version 2.0. A
* copy of the license can be found in the License.html file at the root of this distribution. If
- * you cannot locate the Microsoft Public License, please send an email to
+ * you cannot locate the Apache License, Version 2.0, please send an email to
* dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound
- * by the terms of the Microsoft Public License.
+ * by the terms of the Apache License, Version 2.0.
*
* You must not remove this notice, or any other, from this software.
*
diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/GetIndexBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/GetIndexBinder.cs index 8102cad88a6..730c027c09e 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/GetIndexBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/GetIndexBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/GetMemberBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/GetMemberBinder.cs index 0bf1049c4af..f02ca86ab2b 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/GetMemberBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/GetMemberBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/IDynamicMetaObjectProvider.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/IDynamicMetaObjectProvider.cs index 86140947433..b4314cbdff8 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/IDynamicMetaObjectProvider.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/IDynamicMetaObjectProvider.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/IInvokeOnGetBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/IInvokeOnGetBinder.cs index fd14068f6f9..49d2765be80 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/IInvokeOnGetBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/IInvokeOnGetBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/InvokeBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/InvokeBinder.cs index 6530cc06ef0..248bb542b02 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/InvokeBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/InvokeBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/InvokeMemberBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/InvokeMemberBinder.cs index d3cf6c0ef54..404ff50bbf2 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/InvokeMemberBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/InvokeMemberBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/RuleCache.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/RuleCache.cs index c9db53b1629..a7865f7e6e1 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/RuleCache.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/RuleCache.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/SetIndexBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/SetIndexBinder.cs index f4a3635b111..ea123b86321 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/SetIndexBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/SetIndexBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/SetMemberBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/SetMemberBinder.cs index 77c2a0e6e70..dcda1058803 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/SetMemberBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/SetMemberBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/UnaryOperationBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/UnaryOperationBinder.cs index eb5b1dab1b1..46c704686df 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/UnaryOperationBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/UnaryOperationBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/UpdateDelegates.Generated.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/UpdateDelegates.Generated.cs index eb3c288359e..70a1b92b4f4 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/UpdateDelegates.Generated.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Actions/UpdateDelegates.Generated.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/BinaryExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/BinaryExpression.cs index 0ccacc28038..845e91a2075 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/BinaryExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/BinaryExpression.cs @@ -3,11 +3,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -1336,7 +1336,7 @@ namespace System.Linq.Expressions { } Type delegateType = conversion.Type; - Debug.Assert(typeof(System.Delegate).IsAssignableFrom(delegateType) && delegateType != typeof(System.Delegate)); + Debug.Assert(typeof(System.MulticastDelegate).IsAssignableFrom(delegateType) && delegateType != typeof(System.MulticastDelegate)); MethodInfo method = delegateType.GetMethod("Invoke"); if (method.ReturnType == typeof(void)) { throw Error.UserDefinedOperatorMustNotBeVoid(conversion); @@ -1473,7 +1473,7 @@ namespace System.Linq.Expressions { private static void ValidateOpAssignConversionLambda(LambdaExpression conversion, Expression left, MethodInfo method, ExpressionType nodeType) { Type delegateType = conversion.Type; - Debug.Assert(typeof(System.Delegate).IsAssignableFrom(delegateType) && delegateType != typeof(System.Delegate)); + Debug.Assert(typeof(System.MulticastDelegate).IsAssignableFrom(delegateType) && delegateType != typeof(System.MulticastDelegate)); MethodInfo mi = delegateType.GetMethod("Invoke"); ParameterInfo[] pms = mi.GetParametersCached(); Debug.Assert(pms.Length == conversion.Parameters.Count); diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/BlockExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/BlockExpression.cs index 80f013325f5..1867f3ff056 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/BlockExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/BlockExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/CatchBlock.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/CatchBlock.cs index e6ea7ed49d3..6993ba5bdbe 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/CatchBlock.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/CatchBlock.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ConditionalExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ConditionalExpression.cs index f49a6b8e265..8f49f0f88c4 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ConditionalExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ConditionalExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ConstantExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ConstantExpression.cs index 73c5b8a6722..e338aa71330 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ConstantExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ConstantExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DebugInfoExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DebugInfoExpression.cs index d12dfa09f9d..9f3c3ff15c8 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DebugInfoExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DebugInfoExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DebugViewWriter.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DebugViewWriter.cs index c512ad40246..9ad865fc812 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DebugViewWriter.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DebugViewWriter.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -229,12 +229,7 @@ namespace System.Linq.Expressions { GetMemberBinder getMember; SetMemberBinder setMember; DeleteMemberBinder deleteMember; - GetIndexBinder getIndex; - SetIndexBinder setIndex; - DeleteIndexBinder deleteIndex; InvokeMemberBinder call; - InvokeBinder invoke; - CreateInstanceBinder create; UnaryOperationBinder unary; BinaryOperationBinder binary; @@ -246,17 +241,17 @@ namespace System.Linq.Expressions { return "SetMember " + setMember.Name; } else if ((deleteMember = binder as DeleteMemberBinder) != null) { return "DeleteMember " + deleteMember.Name; - } else if ((getIndex = binder as GetIndexBinder) != null) { + } else if (binder is GetIndexBinder) { return "GetIndex"; - } else if ((setIndex = binder as SetIndexBinder) != null) { + } else if (binder is SetIndexBinder) { return "SetIndex"; - } else if ((deleteIndex = binder as DeleteIndexBinder) != null) { + } else if (binder is DeleteIndexBinder) { return "DeleteIndex"; } else if ((call = binder as InvokeMemberBinder) != null) { return "Call " + call.Name; - } else if ((invoke = binder as InvokeBinder) != null) { + } else if (binder is InvokeBinder) { return "Invoke"; - } else if ((create = binder as CreateInstanceBinder) != null) { + } else if (binder is CreateInstanceBinder) { return "Create"; } else if ((unary = binder as UnaryOperationBinder) != null) { return "UnaryOperation " + unary.Operation; @@ -866,8 +861,6 @@ namespace System.Linq.Expressions { [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Maintainability", "CA1502:AvoidExcessiveComplexity")] protected internal override Expression VisitUnary(UnaryExpression node) { - bool parenthesize = NeedsParentheses(node, node.Operand); - switch (node.NodeType) { case ExpressionType.Convert: Out("(" + node.Type.ToString() + ")"); diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DefaultExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DefaultExpression.cs index dad191f76af..2355f3bd1b8 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DefaultExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DefaultExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DynamicExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DynamicExpression.cs index 25848119465..4358c758658 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DynamicExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/DynamicExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -454,7 +454,7 @@ namespace System.Linq.Expressions { public static DynamicExpression MakeDynamic(Type delegateType, CallSiteBinder binder, IEnumerable<Expression> arguments) { ContractUtils.RequiresNotNull(delegateType, "delegateType"); ContractUtils.RequiresNotNull(binder, "binder"); - if (!delegateType.IsSubclassOf(typeof(Delegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); + if (!delegateType.IsSubclassOf(typeof(MulticastDelegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); var method = GetValidMethodForDynamic(delegateType); @@ -478,9 +478,9 @@ namespace System.Linq.Expressions { /// <see cref="DynamicExpression.Arguments">Arguments</see> set to the specified values. /// </returns> public static DynamicExpression MakeDynamic(Type delegateType, CallSiteBinder binder, Expression arg0) { - ContractUtils.RequiresNotNull(delegateType, "delegatType"); + ContractUtils.RequiresNotNull(delegateType, "delegateType"); ContractUtils.RequiresNotNull(binder, "binder"); - if (!delegateType.IsSubclassOf(typeof(Delegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); + if (!delegateType.IsSubclassOf(typeof(MulticastDelegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); var method = GetValidMethodForDynamic(delegateType); var parameters = method.GetParametersCached(); @@ -507,9 +507,9 @@ namespace System.Linq.Expressions { /// <see cref="DynamicExpression.Arguments">Arguments</see> set to the specified values. /// </returns> public static DynamicExpression MakeDynamic(Type delegateType, CallSiteBinder binder, Expression arg0, Expression arg1) { - ContractUtils.RequiresNotNull(delegateType, "delegatType"); + ContractUtils.RequiresNotNull(delegateType, "delegateType"); ContractUtils.RequiresNotNull(binder, "binder"); - if (!delegateType.IsSubclassOf(typeof(Delegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); + if (!delegateType.IsSubclassOf(typeof(MulticastDelegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); var method = GetValidMethodForDynamic(delegateType); var parameters = method.GetParametersCached(); @@ -539,9 +539,9 @@ namespace System.Linq.Expressions { /// <see cref="DynamicExpression.Arguments">Arguments</see> set to the specified values. /// </returns> public static DynamicExpression MakeDynamic(Type delegateType, CallSiteBinder binder, Expression arg0, Expression arg1, Expression arg2) { - ContractUtils.RequiresNotNull(delegateType, "delegatType"); + ContractUtils.RequiresNotNull(delegateType, "delegateType"); ContractUtils.RequiresNotNull(binder, "binder"); - if (!delegateType.IsSubclassOf(typeof(Delegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); + if (!delegateType.IsSubclassOf(typeof(MulticastDelegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); var method = GetValidMethodForDynamic(delegateType); var parameters = method.GetParametersCached(); @@ -574,9 +574,9 @@ namespace System.Linq.Expressions { /// <see cref="DynamicExpression.Arguments">Arguments</see> set to the specified values. /// </returns> public static DynamicExpression MakeDynamic(Type delegateType, CallSiteBinder binder, Expression arg0, Expression arg1, Expression arg2, Expression arg3) { - ContractUtils.RequiresNotNull(delegateType, "delegatType"); + ContractUtils.RequiresNotNull(delegateType, "delegateType"); ContractUtils.RequiresNotNull(binder, "binder"); - if (!delegateType.IsSubclassOf(typeof(Delegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); + if (!delegateType.IsSubclassOf(typeof(MulticastDelegate))) throw Error.TypeMustBeDerivedFromSystemDelegate(); var method = GetValidMethodForDynamic(delegateType); var parameters = method.GetParametersCached(); diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ElementInit.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ElementInit.cs index 858fdf6cba1..d4e376e3194 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ElementInit.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ElementInit.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/Expression.DebuggerProxy.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/Expression.DebuggerProxy.cs index 4295fb78065..81bfaaab3bf 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/Expression.DebuggerProxy.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/Expression.DebuggerProxy.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/Expression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/Expression.cs index 2c1b1ef6036..b2ef4fc3917 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/Expression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/Expression.cs @@ -2,11 +2,11 @@ *
* Copyright (c) Microsoft Corporation.
*
- * This source code is subject to terms and conditions of the Microsoft Public License. A
+ * This source code is subject to terms and conditions of the Apache License, Version 2.0. A
* copy of the license can be found in the License.html file at the root of this distribution. If
- * you cannot locate the Microsoft Public License, please send an email to
+ * you cannot locate the Apache License, Version 2.0, please send an email to
* dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound
- * by the terms of the Microsoft Public License.
+ * by the terms of the Apache License, Version 2.0.
*
* You must not remove this notice, or any other, from this software.
*
@@ -326,6 +326,16 @@ namespace System.Linq.Expressions { return ((ReadOnlyCollection<T>)collectionOrT)[0];
}
+#if SILVERLIGHT
+#if !CLR2
+ // Quirks mode for Expression Trees as they existed in Silverlight 2 and 3
+ internal readonly static bool SilverlightQuirks =
+ AppDomain.CurrentDomain.IsCompatibilitySwitchSet("APP_EARLIER_THAN_SL4.0").GetValueOrDefault();
+#else
+ internal readonly static bool SilverlightQuirks = true;
+#endif
+#endif
+
private static void RequiresCanRead(Expression expression, string paramName) {
if (expression == null) {
throw new ArgumentNullException(paramName);
diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ExpressionStringBuilder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ExpressionStringBuilder.cs index 0b96c2b9c97..34f9f3bb5db 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ExpressionStringBuilder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ExpressionStringBuilder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -162,12 +162,7 @@ namespace System.Linq.Expressions { GetMemberBinder getMember; SetMemberBinder setMember; DeleteMemberBinder deleteMember; - GetIndexBinder getIndex; - SetIndexBinder setIndex; - DeleteIndexBinder deleteIndex; InvokeMemberBinder call; - InvokeBinder invoke; - CreateInstanceBinder create; UnaryOperationBinder unary; BinaryOperationBinder binary; @@ -179,17 +174,17 @@ namespace System.Linq.Expressions { return "SetMember " + setMember.Name; } else if ((deleteMember = binder as DeleteMemberBinder) != null) { return "DeleteMember " + deleteMember.Name; - } else if ((getIndex = binder as GetIndexBinder) != null) { + } else if (binder is GetIndexBinder) { return "GetIndex"; - } else if ((setIndex = binder as SetIndexBinder) != null) { + } else if (binder is SetIndexBinder) { return "SetIndex"; - } else if ((deleteIndex = binder as DeleteIndexBinder) != null) { + } else if (binder is DeleteIndexBinder) { return "DeleteIndex"; } else if ((call = binder as InvokeMemberBinder) != null) { return "Call " + call.Name; - } else if ((invoke = binder as InvokeBinder) != null) { + } else if (binder is InvokeBinder) { return "Invoke"; - } else if ((create = binder as CreateInstanceBinder) != null) { + } else if (binder is CreateInstanceBinder) { return "Create"; } else if ((unary = binder as UnaryOperationBinder) != null) { return unary.Operation.ToString(); @@ -201,6 +196,10 @@ namespace System.Linq.Expressions { } private void VisitExpressions<T>(char open, IList<T> expressions, char close) where T : Expression { + VisitExpressions(open, expressions, close, ", "); + } + + private void VisitExpressions<T>(char open, IList<T> expressions, char close, string seperator) where T : Expression { Out(open); if (expressions != null) { bool isFirst = true; @@ -208,7 +207,7 @@ namespace System.Linq.Expressions { if (isFirst) { isFirst = false; } else { - Out(", "); + Out(seperator); } Visit(e); } @@ -232,11 +231,30 @@ namespace System.Linq.Expressions { } else { string op; switch (node.NodeType) { + // AndAlso and OrElse were unintentionally changed in + // CLR 4. We changed them to "AndAlso" and "OrElse" to + // be 3.5 compatible, but it turns out 3.5 shipped with + // "&&" and "||". Oops. + case ExpressionType.AndAlso: + op = "AndAlso"; +#if SILVERLIGHT + if (Expression.SilverlightQuirks) op = "&&"; +#endif + break; + case ExpressionType.OrElse: + op = "OrElse"; +#if SILVERLIGHT + if (Expression.SilverlightQuirks) op = "||"; +#endif + break; case ExpressionType.Assign: op = "="; break; - case ExpressionType.Equal: op = "=="; break; + case ExpressionType.Equal: + op = "=="; +#if SILVERLIGHT + if (Expression.SilverlightQuirks) op = "="; +#endif + break; case ExpressionType.NotEqual: op = "!="; break; - case ExpressionType.AndAlso: op = "AndAlso"; break; - case ExpressionType.OrElse: op = "OrElse"; break; case ExpressionType.GreaterThan: op = ">"; break; case ExpressionType.LessThan: op = "<"; break; case ExpressionType.GreaterThanOrEqual: op = ">="; break; @@ -311,11 +329,17 @@ namespace System.Linq.Expressions { if (node.IsByRef) { Out("ref "); } - if (String.IsNullOrEmpty(node.Name)) { - int id = GetParamId(node); - Out("Param_" + id); + string name = node.Name; + if (String.IsNullOrEmpty(name)) { +#if SILVERLIGHT + if (Expression.SilverlightQuirks) { + Out(name ?? "<param>"); + return node; + } +#endif + Out("Param_" + GetParamId(node)); } else { - Out(node.Name); + Out(name); } return node; } @@ -467,15 +491,23 @@ namespace System.Linq.Expressions { protected override ElementInit VisitElementInit(ElementInit initializer) { Out(initializer.AddMethod.ToString()); - VisitExpressions('(', initializer.Arguments, ')'); + string sep = ", "; +#if SILVERLIGHT + if (Expression.SilverlightQuirks) sep = ","; +#endif + VisitExpressions('(', initializer.Arguments, ')', sep); return initializer; } protected internal override Expression VisitInvocation(InvocationExpression node) { Out("Invoke("); Visit(node.Expression); + string sep = ", "; +#if SILVERLIGHT + if (Expression.SilverlightQuirks) sep = ","; +#endif for (int i = 0, n = node.Arguments.Count; i < n; i++) { - Out(", "); + Out(sep); Visit(node.Arguments[i]); } Out(")"); @@ -522,15 +554,46 @@ namespace System.Linq.Expressions { return node; } +#if SILVERLIGHT + private static PropertyInfo GetPropertyNoThrow(MethodInfo method) { + if (method == null) + return null; + Type type = method.DeclaringType; + BindingFlags flags = BindingFlags.Public | BindingFlags.NonPublic; + flags |= (method.IsStatic) ? BindingFlags.Static : BindingFlags.Instance; + PropertyInfo[] props = type.GetProperties(flags); + foreach (PropertyInfo pi in props) { + if (pi.CanRead && method == pi.GetGetMethod(true)) { + return pi; + } + if (pi.CanWrite && method == pi.GetSetMethod(true)) { + return pi; + } + } + return null; + } +#endif + protected internal override Expression VisitNew(NewExpression node) { Out("new " + node.Type.Name); Out("("); + var members = node.Members; for (int i = 0; i < node.Arguments.Count; i++) { if (i > 0) { Out(", "); } - if (node.Members != null) { - Out(node.Members[i].Name); + if (members != null) { + string name = members[i].Name; +#if SILVERLIGHT + // Members can be the get/set methods rather than the fields/properties + PropertyInfo pi = null; + if (Expression.SilverlightQuirks && + members[i].MemberType == MemberTypes.Method && + (pi = GetPropertyNoThrow((MethodInfo)members[i])) != null) { + name = pi.Name; + } +#endif + Out(name); Out(" = "); } Visit(node.Arguments[i]); diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ExpressionType.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ExpressionType.cs index 297d4d8d893..11fbb1dcd4a 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ExpressionType.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ExpressionType.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ExpressionVisitor.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ExpressionVisitor.cs index 04c0bf9576c..179152bc027 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ExpressionVisitor.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ExpressionVisitor.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/GotoExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/GotoExpression.cs index a3434bbc9b9..0bd9827096a 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/GotoExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/GotoExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -366,11 +366,9 @@ namespace System.Linq.Expressions { if (expectedType != typeof(void)) { if (!TypeUtils.AreReferenceAssignable(expectedType, value.Type)) { // C# autoquotes return values, so we'll do that here - if (TypeUtils.IsSameOrSubclass(typeof(LambdaExpression), expectedType) && - expectedType.IsAssignableFrom(value.GetType())) { - value = Expression.Quote(value); + if (!TryQuote(expectedType, ref value)) { + throw Error.ExpressionTypeDoesNotMatchLabel(value.Type, expectedType); } - throw Error.ExpressionTypeDoesNotMatchLabel(value.Type, expectedType); } } } diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/IArgumentProvider.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/IArgumentProvider.cs index cce7fa7aaee..6dc58ea1765 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/IArgumentProvider.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/IArgumentProvider.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/IndexExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/IndexExpression.cs index 61296c002de..1bbf207cb11 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/IndexExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/IndexExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -429,9 +429,7 @@ namespace System.Linq.Expressions { TypeUtils.ValidateType(pType); if (!TypeUtils.AreReferenceAssignable(pType, arg.Type)) { - if (TypeUtils.IsSameOrSubclass(typeof(LambdaExpression), pType) && pType.IsAssignableFrom(arg.GetType())) { - arg = Expression.Quote(arg); - } else { + if (!TryQuote(pType, ref arg)) { throw Error.ExpressionTypeDoesNotMatchMethodParameter(arg.Type, pType, method); } } diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/InvocationExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/InvocationExpression.cs index 5f68eaeec51..05501f42d93 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/InvocationExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/InvocationExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -191,9 +191,7 @@ namespace System.Linq.Expressions { /// <param name="expression">The expression to be invoked.</param> internal static MethodInfo GetInvokeMethod(Expression expression) { Type delegateType = expression.Type; - if (delegateType == typeof(Delegate)) { - throw Error.ExpressionTypeNotInvocable(delegateType); - } else if (!typeof(Delegate).IsAssignableFrom(expression.Type)) { + if (!expression.Type.IsSubclassOf(typeof(MulticastDelegate))) { Type exprType = TypeUtils.FindGenericType(typeof(Expression<>), expression.Type); if (exprType == null) { throw Error.ExpressionTypeNotInvocable(expression.Type); diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LabelExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LabelExpression.cs index 5d684cf9796..86fc3dfdb40 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LabelExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LabelExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LabelTarget.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LabelTarget.cs index acc3d01b88a..b9c814995b3 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LabelTarget.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LabelTarget.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LambdaExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LambdaExpression.cs index 0ea69566d76..7a53dd04c27 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LambdaExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LambdaExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -508,7 +508,7 @@ namespace System.Linq.Expressions { ContractUtils.RequiresNotNull(delegateType, "delegateType"); RequiresCanRead(body, "body"); - if (!typeof(Delegate).IsAssignableFrom(delegateType) || delegateType == typeof(Delegate)) { + if (!typeof(MulticastDelegate).IsAssignableFrom(delegateType) || delegateType == typeof(MulticastDelegate)) { throw Error.LambdaTypeMustBeDerivedFromSystemDelegate(); } @@ -553,9 +553,7 @@ namespace System.Linq.Expressions { throw Error.IncorrectNumberOfLambdaDeclarationParameters(); } if (mi.ReturnType != typeof(void) && !TypeUtils.AreReferenceAssignable(mi.ReturnType, body.Type)) { - if (TypeUtils.IsSameOrSubclass(typeof(LambdaExpression), mi.ReturnType) && mi.ReturnType.IsAssignableFrom(body.GetType())) { - body = Expression.Quote(body); - } else { + if (!TryQuote(mi.ReturnType, ref body)) { throw Error.ExpressionTypeDoesNotMatchReturn(body.Type, mi.ReturnType); } } diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ListArgumentProvider.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ListArgumentProvider.cs index ddd1a4c4f41..5d2292b46bc 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ListArgumentProvider.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ListArgumentProvider.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ListInitExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ListInitExpression.cs index 3f988020e4c..71bd0f6c1c4 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ListInitExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ListInitExpression.cs @@ -2,11 +2,11 @@ *
* Copyright (c) Microsoft Corporation.
*
- * This source code is subject to terms and conditions of the Microsoft Public License. A
+ * This source code is subject to terms and conditions of the Apache License, Version 2.0. A
* copy of the license can be found in the License.html file at the root of this distribution. If
- * you cannot locate the Microsoft Public License, please send an email to
+ * you cannot locate the Apache License, Version 2.0, please send an email to
* dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound
- * by the terms of the Microsoft Public License.
+ * by the terms of the Apache License, Version 2.0.
*
* You must not remove this notice, or any other, from this software.
*
diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LoopExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LoopExpression.cs index dbf082cade4..5c216ab2d94 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LoopExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/LoopExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberAssignment.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberAssignment.cs index 8baca724a0d..d08a85ce55d 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberAssignment.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberAssignment.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberBinding.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberBinding.cs index 5ed186aab07..fdeafaf79ae 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberBinding.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberBinding.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberExpression.cs index 4042eab4cef..e314cda8456 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberInitExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberInitExpression.cs index 878803ee5a9..2eb7fe33db0 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberInitExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberInitExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberListBinding.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberListBinding.cs index 741cf243f3d..0badf175f46 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberListBinding.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberListBinding.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberMemberBinding.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberMemberBinding.cs index 1ea2ca8019c..9fcc4312b52 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberMemberBinding.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MemberMemberBinding.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MethodCallExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MethodCallExpression.cs index 4f8972a492c..66b3bb001dc 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MethodCallExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/MethodCallExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -814,6 +814,9 @@ namespace System.Linq.Expressions { private static void ValidateStaticOrInstanceMethod(Expression instance, MethodInfo method) { if (method.IsStatic) { +#if SILVERLIGHT + if (SilverlightQuirks) return; +#endif if (instance != null) throw new ArgumentException(Strings.OnlyStaticMethodsHaveNullInstance, "instance"); } else { if (instance == null) throw new ArgumentException(Strings.OnlyStaticMethodsHaveNullInstance, "method"); @@ -890,9 +893,7 @@ namespace System.Linq.Expressions { } TypeUtils.ValidateType(pType); if (!TypeUtils.AreReferenceAssignable(pType, arg.Type)) { - if (TypeUtils.IsSameOrSubclass(typeof(LambdaExpression), pType) && pType.IsAssignableFrom(arg.GetType())) { - arg = Expression.Quote(arg); - } else { + if (!TryQuote(pType, ref arg)) { // Throw the right error for the node we were given switch (nodeKind) { case ExpressionType.New: @@ -910,6 +911,23 @@ namespace System.Linq.Expressions { return arg; } + // Attempts to auto-quote the expression tree. Returns true if it succeeded, false otherwise. + private static bool TryQuote(Type parameterType, ref Expression argument) { + // We used to allow quoting of any expression, but the behavior of + // quote (produce a new tree closed over parameter values), only + // works consistently for lambdas + Type quoteable = typeof(LambdaExpression); +#if SILVERLIGHT + if (SilverlightQuirks) quoteable = typeof(Expression); +#endif + if (TypeUtils.IsSameOrSubclass(quoteable, parameterType) && + parameterType.IsAssignableFrom(argument.GetType())) { + argument = Expression.Quote(argument); + return true; + } + return false; + } + private static MethodInfo FindMethod(Type type, string methodName, Type[] typeArgs, Expression[] args, BindingFlags flags) { MemberInfo[] members = type.FindMembers(MemberTypes.Method, flags, Type.FilterNameIgnoreCase, methodName); if (members == null || members.Length == 0) diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/NewArrayExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/NewArrayExpression.cs index 9f18554533f..e51b6f20a1e 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/NewArrayExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/NewArrayExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -158,9 +158,7 @@ namespace System.Linq.Expressions { RequiresCanRead(expr, "initializers"); if (!TypeUtils.AreReferenceAssignable(type, expr.Type)) { - if (TypeUtils.IsSameOrSubclass(typeof(LambdaExpression), type) && type.IsAssignableFrom(expr.GetType())) { - expr = Expression.Quote(expr); - } else { + if (!TryQuote(type, ref expr)){ throw Error.ExpressionTypeCannotInitializeArrayType(expr.Type, type); } if (newList == null) { diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/NewExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/NewExpression.cs index edfc486c536..0b3381e92ec 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/NewExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/NewExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -247,9 +247,7 @@ namespace System.Linq.Expressions { Type memberType; ValidateAnonymousTypeMember(ref member, out memberType); if (!TypeUtils.AreReferenceAssignable(memberType, arg.Type)) { - if (TypeUtils.IsSameOrSubclass(typeof(LambdaExpression), memberType) && memberType.IsAssignableFrom(arg.GetType())) { - arg = Expression.Quote(arg); - } else { + if (!TryQuote(memberType, ref arg)) { throw Error.ArgumentTypeDoesNotMatchMember(arg.Type, memberType); } } @@ -259,9 +257,7 @@ namespace System.Linq.Expressions { pType = pType.GetElementType(); } if (!TypeUtils.AreReferenceAssignable(pType, arg.Type)) { - if (TypeUtils.IsSameOrSubclass(typeof(LambdaExpression), pType) && pType.IsAssignableFrom(arg.Type)) { - arg = Expression.Quote(arg); - } else { + if (!TryQuote(pType, ref arg)) { throw Error.ExpressionTypeDoesNotMatchConstructorParameter(arg.Type, pType); } } @@ -307,7 +303,7 @@ namespace System.Linq.Expressions { throw Error.ArgumentMustBeInstanceMember(); } memberType = field.FieldType; - break; + return; case MemberTypes.Property: PropertyInfo pi = member as PropertyInfo; if (!pi.CanRead) { @@ -317,20 +313,27 @@ namespace System.Linq.Expressions { throw Error.ArgumentMustBeInstanceMember(); } memberType = pi.PropertyType; - break; + return; case MemberTypes.Method: MethodInfo method = member as MethodInfo; if (method.IsStatic) { throw Error.ArgumentMustBeInstanceMember(); } - +#if SILVERLIGHT + if (SilverlightQuirks) { + // we used to just store the MethodInfo + memberType = method.ReturnType; + return; + } +#endif PropertyInfo prop = GetProperty(method); member = prop; memberType = prop.PropertyType; - break; + return; default: throw Error.ArgumentMustBeFieldInfoOrPropertInfoOrMethod(); } + // don't add code here, we've already returned } } } diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ParameterExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ParameterExpression.cs index aa55846cf57..df225f11b7a 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ParameterExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/ParameterExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/RuntimeVariablesExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/RuntimeVariablesExpression.cs index 6f3e87d06fd..5d7e53efb26 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/RuntimeVariablesExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/RuntimeVariablesExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/SwitchCase.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/SwitchCase.cs index 78a5949e85b..2316a65934e 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/SwitchCase.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/SwitchCase.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/SwitchExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/SwitchExpression.cs index 5fcb902d2a2..cff43227771 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/SwitchExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/SwitchExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/SymbolDocumentInfo.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/SymbolDocumentInfo.cs index bfe265048c9..1b20bafe5e2 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/SymbolDocumentInfo.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/SymbolDocumentInfo.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/TryExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/TryExpression.cs index 39a0f65e535..0959ac7cea4 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/TryExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/TryExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/TypeBinaryExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/TypeBinaryExpression.cs index 28be5aa7439..ef5ba7de9f0 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/TypeBinaryExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/TypeBinaryExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/TypeUtils.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/TypeUtils.cs index f582eab01ab..10b518510a2 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/TypeUtils.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/TypeUtils.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -280,7 +280,7 @@ namespace System.Dynamic.Utils { private static bool IsDelegate(Type t) { Debug.Assert(t != null); - return t.IsSubclassOf(typeof(System.Delegate)); + return t.IsSubclassOf(typeof(System.MulticastDelegate)); } internal static bool IsLegalExplicitVariantDelegateConversion(Type source, Type dest) diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/UnaryExpression.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/UnaryExpression.cs index 87fdd414dd5..b71b138c705 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/UnaryExpression.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Ast/UnaryExpression.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -787,7 +787,11 @@ namespace System.Linq.Expressions { ///<paramref name="expression" /> is null.</exception> public static UnaryExpression Quote(Expression expression) { RequiresCanRead(expression, "expression"); - if (!(expression is LambdaExpression)) throw Error.QuotedExpressionMustBeLambda(); + bool validQuote = expression is LambdaExpression; +#if SILVERLIGHT + validQuote |= SilverlightQuirks; +#endif + if (!validQuote) throw Error.QuotedExpressionMustBeLambda(); return new UnaryExpression(ExpressionType.Quote, expression, expression.GetType(), null); } diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/AnalyzedTree.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/AnalyzedTree.cs index 99ac850ad06..3b8c6c2a86f 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/AnalyzedTree.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/AnalyzedTree.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/AssemblyGen.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/AssemblyGen.cs index 5a05cb81ef9..b908bcfadbc 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/AssemblyGen.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/AssemblyGen.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/BoundConstants.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/BoundConstants.cs index 68ca16249bb..5afdbd31f7b 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/BoundConstants.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/BoundConstants.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/Closure.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/Closure.cs index e18aefd4155..0adc8608ffa 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/Closure.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/Closure.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/CompilerScope.Storage.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/CompilerScope.Storage.cs index 5e1cf188d92..e736ac60f3f 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/CompilerScope.Storage.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/CompilerScope.Storage.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/CompilerScope.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/CompilerScope.cs index ac85f649dae..ab3d884bd8c 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/CompilerScope.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/CompilerScope.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -321,8 +321,14 @@ namespace System.Linq.Expressions.Compiler { ResolveVariable(v, _closureHoistedLocals).EmitLoad(); lc.IL.Emit(OpCodes.Newobj, boxType.GetConstructor(new Type[] { v.Type })); } else { +#if CLR2 + // array[i] = new StrongBox<T>(default(T)); + lc.IL.EmitDefault(v.Type); + lc.IL.Emit(OpCodes.Newobj, boxType.GetConstructor(new Type[] { v.Type })); +#else // array[i] = new StrongBox<T>(); lc.IL.Emit(OpCodes.Newobj, boxType.GetConstructor(Type.EmptyTypes)); +#endif } // if we want to cache this into a local, do it now if (ShouldCache(v)) { diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/ConstantCheck.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/ConstantCheck.cs index d632c72b690..b901792925c 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/ConstantCheck.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/ConstantCheck.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/DebugInfoGenerator.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/DebugInfoGenerator.cs index 9516f3a0b8c..c20cde6f58a 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/DebugInfoGenerator.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/DebugInfoGenerator.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/DelegateHelpers.Generated.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/DelegateHelpers.Generated.cs index b937e2f8049..fe319376ff5 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/DelegateHelpers.Generated.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/DelegateHelpers.Generated.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/DelegateHelpers.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/DelegateHelpers.cs index b4f84a44ad0..47079f8894d 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/DelegateHelpers.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/DelegateHelpers.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/ExpressionQuoter.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/ExpressionQuoter.cs index f7e8b7bc5cc..059308be44e 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/ExpressionQuoter.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/ExpressionQuoter.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/HoistedLocals.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/HoistedLocals.cs index 37d8d1eeacb..8c315fff4f7 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/HoistedLocals.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/HoistedLocals.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/ILGen.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/ILGen.cs index 348b8d1a556..c08076ec0d3 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/ILGen.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/ILGen.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -612,6 +612,8 @@ namespace System.Linq.Expressions.Compiler { typeTo.IsInterface || typeFrom == typeof(object) || // boxing cast typeTo == typeof(object) || + typeFrom == typeof(System.Enum) || + typeFrom == typeof(System.ValueType) || TypeUtils.IsLegalExplicitVariantDelegateConversion(typeFrom, typeTo)) { il.EmitCastToType(typeFrom, typeTo); diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/KeyedQueue.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/KeyedQueue.cs index 86191f2dd46..fdd6e2f8066 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/KeyedQueue.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/KeyedQueue.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LabelInfo.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LabelInfo.cs index 261b1c976db..435f066910a 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LabelInfo.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LabelInfo.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Address.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Address.cs index 9eea1b9c859..cb208f2b9fa 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Address.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Address.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Binary.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Binary.cs index 2d5d51fce75..6e4ac1f0112 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Binary.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Binary.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.ControlFlow.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.ControlFlow.cs index 1fc97c83b94..0501f9d660a 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.ControlFlow.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.ControlFlow.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Expressions.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Expressions.cs index 0321807ab85..beb4125b576 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Expressions.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Expressions.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Generated.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Generated.cs index 62f5877c1ed..405eb6ddf09 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Generated.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Generated.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Lambda.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Lambda.cs index 2804201ac19..a2e58076f08 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Lambda.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Lambda.cs @@ -2,11 +2,11 @@ *
* Copyright (c) Microsoft Corporation.
*
- * This source code is subject to terms and conditions of the Microsoft Public License. A
+ * This source code is subject to terms and conditions of the Apache License, Version 2.0. A
* copy of the license can be found in the License.html file at the root of this distribution. If
- * you cannot locate the Microsoft Public License, please send an email to
+ * you cannot locate the Apache License, Version 2.0, please send an email to
* dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound
- * by the terms of the Microsoft Public License.
+ * by the terms of the Apache License, Version 2.0.
*
* You must not remove this notice, or any other, from this software.
*
diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Logical.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Logical.cs index 0943646df93..5c846fb7e0f 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Logical.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Logical.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -175,7 +175,6 @@ namespace System.Linq.Expressions.Compiler { // if not null, call conversion _ilg.MarkLabel(labNotNull); Debug.Assert(b.Conversion.Parameters.Count == 1); - ParameterExpression p = b.Conversion.Parameters[0]; // emit the delegate instance EmitLambdaExpression(b.Conversion); diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Statements.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Statements.cs index 2a4c6994ffb..4fbbe062d6d 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Statements.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Statements.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -43,8 +43,6 @@ namespace System.Linq.Expressions.Compiler { int count = node.ExpressionCount; CompilationFlags tailCall = flags & CompilationFlags.EmitAsTailCallMask; - CompilationFlags middleTailCall = tailCall == CompilationFlags.EmitAsNoTail ? CompilationFlags.EmitAsNoTail : CompilationFlags.EmitAsMiddle; - for (int index = 0; index < count - 1; index++) { var e = node.GetExpression(index); var next = node.GetExpression(index + 1); @@ -57,19 +55,23 @@ namespace System.Linq.Expressions.Compiler { continue; } } - // In the middle of the block. - // We may do better here by marking it as Tail if the following expressions are not going to emit any IL. - var tailCallFlag = middleTailCall; - - var g = next as GotoExpression; - if (g != null && (g.Value == null || !Significant(g.Value))) { - var labelInfo = ReferenceLabel(g.Target); - if (labelInfo.CanReturn) { + + CompilationFlags tailCallFlag; + if (tailCall != CompilationFlags.EmitAsNoTail) { + var g = next as GotoExpression; + if (g != null && (g.Value == null || !Significant(g.Value)) && ReferenceLabel(g.Target).CanReturn) { // Since tail call flags are not passed into EmitTryExpression, CanReturn means the goto will be emitted // as Ret. Therefore we can emit the current expression with tail call. tailCallFlag = CompilationFlags.EmitAsTail; + } else { + // In the middle of the block. + // We may do better here by marking it as Tail if the following expressions are not going to emit any IL. + tailCallFlag = CompilationFlags.EmitAsMiddle; } + } else { + tailCallFlag = CompilationFlags.EmitAsNoTail; } + flags = UpdateEmitAsTailCallFlag(flags, tailCallFlag); EmitExpressionAsVoid(e, flags); } diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Unary.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Unary.cs index d9f63af9bc8..1ace72b4e9d 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Unary.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.Unary.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -105,10 +105,9 @@ namespace System.Linq.Expressions.Compiler { if (operandIsNullable) { switch (op) { case ExpressionType.Not: { - if (operandType != typeof(bool?)) + if (operandType != typeof(bool?)) { goto case ExpressionType.Negate; - - Label labIfNull = _ilg.DefineLabel(); + } Label labEnd = _ilg.DefineLabel(); LocalBuilder loc = GetLocal(operandType); diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.cs index 6c9fb1dea83..4b004556c47 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/LambdaCompiler.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -310,7 +310,7 @@ namespace System.Linq.Expressions.Compiler { /// </summary> private MemberExpression CreateLazyInitializedField<T>(string name) { if (_method is DynamicMethod) { - return Expression.Field(Expression.Constant(new StrongBox<T>()), "Value"); + return Expression.Field(Expression.Constant(new StrongBox<T>(default(T))), "Value"); } else { return Expression.Field(null, CreateStaticField(name, typeof(T))); } diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/OffsetTrackingILGenerator.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/OffsetTrackingILGenerator.cs index 3a9c21df1f1..0630f0be074 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/OffsetTrackingILGenerator.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/OffsetTrackingILGenerator.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/RuntimeVariableList.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/RuntimeVariableList.cs index e1b1209ff2f..b69a5a442cc 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/RuntimeVariableList.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/RuntimeVariableList.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/Set.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/Set.cs index 585557365ba..96ec6d33974 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/Set.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/Set.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.Bindings.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.Bindings.cs index 1a484069b39..95ceba84068 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.Bindings.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.Bindings.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.Generated.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.Generated.cs index 13be379e11c..f96780dd8b8 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.Generated.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.Generated.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.Temps.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.Temps.cs index 541f3225a3c..cee6fab837b 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.Temps.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.Temps.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.cs index 387e3929194..38ba4a45170 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/StackSpiller.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/SymbolDocumentGenerator.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/SymbolDocumentGenerator.cs index b597201685f..bd883fe92d3 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/SymbolDocumentGenerator.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/SymbolDocumentGenerator.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/VariableBinder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/VariableBinder.cs index 74482b5c97f..0984a04619e 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/VariableBinder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Compiler/VariableBinder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Microsoft.Scripting.Core.csproj b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Microsoft.Scripting.Core.csproj index 69b1f0150ce..5d67e73f9d4 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Microsoft.Scripting.Core.csproj +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Microsoft.Scripting.Core.csproj @@ -1,249 +1,227 @@ -<?xml version="1.0" encoding="utf-8"?> -<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> - - - <PropertyGroup> - <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> - <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> - <ProductVersion>10.0.20624</ProductVersion> - <SchemaVersion>2.0</SchemaVersion> - <ProjectGuid>{2AE75F5A-CD1F-4925-9647-AF4D1C282FB4}</ProjectGuid> - <OutputType>Library</OutputType> - <AppDesignerFolder>Properties</AppDesignerFolder> - <RootNamespace>System.Scripting</RootNamespace> - <AssemblyName>Microsoft.Scripting.Core</AssemblyName> -<DocumentationFile>$(OutputPath)\Microsoft.Scripting.Core.XML</DocumentationFile> - <NoWarn>1591</NoWarn> -<AssemblyOriginatorKeyFile>$(SolutionDir)Runtime\MSSharedLibKey.snk</AssemblyOriginatorKeyFile> - <SignAssembly Condition="'$(SignAssembly)' == '' And Exists('$(AssemblyOriginatorKeyFile)')">true</SignAssembly> - <SignedSym Condition="'$(SignAssembly)' == 'true'">SIGNED</SignedSym> - <DelaySign>true</DelaySign> - <SilverlightPath Condition="'$(SilverlightPath)' == ''">$(ProgramFiles)\Microsoft Silverlight\3.0.40818.0\</SilverlightPath> - <BaseAddress>855638016</BaseAddress> - <TargetFrameworkVersion>v2.0</TargetFrameworkVersion> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'FxCop|AnyCPU' "> - <DebugType>pdbonly</DebugType> - <Optimize>true</Optimize> -<OutputPath>$(SolutionDir)..\Bin\fxcop\</OutputPath> - <DefineConstants>TRACE;$(SignedSym);CLR2</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <RunCodeAnalysis>true</RunCodeAnalysis> - <CodeAnalysisRules>-Microsoft.Usage#CA2209;+!Microsoft.Design#CA1012;-!Microsoft.Design#CA2210;+!Microsoft.Design#CA1040;+!Microsoft.Design#CA1005;+!Microsoft.Design#CA1020;-!Microsoft.Design#CA1021;+!Microsoft.Design#CA1010;+!Microsoft.Design#CA1011;+!Microsoft.Design#CA1009;+!Microsoft.Design#CA1050;+!Microsoft.Design#CA1026;+!Microsoft.Design#CA1019;+!Microsoft.Design#CA1031;+!Microsoft.Design#CA1047;+!Microsoft.Design#CA1000;+!Microsoft.Design#CA1048;+!Microsoft.Design#CA1051;+!Microsoft.Design#CA1002;+!Microsoft.Design#CA1061;+!Microsoft.Design#CA1006;+!Microsoft.Design#CA1046;+!Microsoft.Design#CA1045;+!Microsoft.Design#CA1065;+!Microsoft.Design#CA1038;+!Microsoft.Design#CA1008;+!Microsoft.Design#CA1028;+!Microsoft.Design#CA1064;-!Microsoft.Design#CA1004;+!Microsoft.Design#CA1035;+!Microsoft.Design#CA1063;+!Microsoft.Design#CA1032;+!Microsoft.Design#CA1023;+!Microsoft.Design#CA1033;+!Microsoft.Design#CA1039;+!Microsoft.Design#CA1016;+!Microsoft.Design#CA1014;+!Microsoft.Design#CA1017;+!Microsoft.Design#CA1018;+!Microsoft.Design#CA1027;+!Microsoft.Design#CA1059;+!Microsoft.Design#CA1060;+!Microsoft.Design#CA1034;+!Microsoft.Design#CA1013;+!Microsoft.Design#CA1036;+!Microsoft.Design#CA1044;+!Microsoft.Design#CA1041;+!Microsoft.Design#CA1025;+!Microsoft.Design#CA1052;+!Microsoft.Design#CA1053;+!Microsoft.Design#CA1057;+!Microsoft.Design#CA1058;+!Microsoft.Design#CA1001;+!Microsoft.Design#CA1049;+!Microsoft.Design#CA1054;+!Microsoft.Design#CA1056;+!Microsoft.Design#CA1055;+!Microsoft.Design#CA1030;+!Microsoft.Design#CA1003;+!Microsoft.Design#CA1007;+!Microsoft.Design#CA1043;+!Microsoft.Design#CA1024;+!Microsoft.Globalization#CA1301;+!Microsoft.Globalization#CA1302;+!Microsoft.Globalization#CA1308;+!Microsoft.Globalization#CA1306;+!Microsoft.Globalization#CA1304;+!Microsoft.Globalization#CA1305;+!Microsoft.Globalization#CA2101;+!Microsoft.Globalization#CA1300;+!Microsoft.Globalization#CA1307;+!Microsoft.Globalization#CA1309;+!Microsoft.Interoperability#CA1403;+!Microsoft.Interoperability#CA1406;+!Microsoft.Interoperability#CA1413;+!Microsoft.Interoperability#CA1402;+!Microsoft.Interoperability#CA1407;+!Microsoft.Interoperability#CA1404;+!Microsoft.Interoperability#CA1410;+!Microsoft.Interoperability#CA1411;+!Microsoft.Interoperability#CA1405;+!Microsoft.Interoperability#CA1409;+!Microsoft.Interoperability#CA1415;+!Microsoft.Interoperability#CA1408;+!Microsoft.Interoperability#CA1414;+!Microsoft.Interoperability#CA1412;+!Microsoft.Interoperability#CA1400;+!Microsoft.Interoperability#CA1401;+!Microsoft.Maintainability#CA1506;+!Microsoft.Maintainability#CA1502;+!Microsoft.Maintainability#CA1501;+!Microsoft.Maintainability#CA1505;+!Microsoft.Maintainability#CA1504;+!Microsoft.Maintainability#CA1500;+!Microsoft.Mobility#CA1600;+!Microsoft.Mobility#CA1601;-!Microsoft.Naming#CA1702;+!Microsoft.Naming#CA1700;+!Microsoft.Naming#CA1712;+!Microsoft.Naming#CA1713;+!Microsoft.Naming#CA1714;+!Microsoft.Naming#CA1709;-!Microsoft.Naming#CA1704;+!Microsoft.Naming#CA1708;+!Microsoft.Naming#CA1715;-!Microsoft.Naming#CA1710;-!Microsoft.Naming#CA1720;+!Microsoft.Naming#CA1707;+!Microsoft.Naming#CA1722;-!Microsoft.Naming#CA1711;+!Microsoft.Naming#CA1716;+!Microsoft.Naming#CA1717;+!Microsoft.Naming#CA1725;+!Microsoft.Naming#CA1719;+!Microsoft.Naming#CA1721;+!Microsoft.Naming#CA1701;+!Microsoft.Naming#CA1703;+!Microsoft.Naming#CA1724;-!Microsoft.Naming#CA1726;+!Microsoft.Performance#CA1809;+!Microsoft.Performance#CA1811;+!Microsoft.Performance#CA1812;+!Microsoft.Performance#CA1813;+!Microsoft.Performance#CA1823;+!Microsoft.Performance#CA1800;+!Microsoft.Performance#CA1805;+!Microsoft.Performance#CA1810;+!Microsoft.Performance#CA1824;+!Microsoft.Performance#CA1822;+!Microsoft.Performance#CA1815;+!Microsoft.Performance#CA1814;+!Microsoft.Performance#CA1819;+!Microsoft.Performance#CA1821;+!Microsoft.Performance#CA1804;+!Microsoft.Performance#CA1820;+!Microsoft.Performance#CA1802;+!Microsoft.Portability#CA1901;+!Microsoft.Portability#CA1900;+!Microsoft.Reliability#CA2001;+!Microsoft.Reliability#CA2002;+!Microsoft.Reliability#CA2003;+!Microsoft.Reliability#CA2004;+!Microsoft.Reliability#CA2006;+!Microsoft.Security#CA2116;+!Microsoft.Security#CA2117;+!Microsoft.Security#CA2105;+!Microsoft.Security#CA2115;+!Microsoft.Security#CA2102;+!Microsoft.Security#CA2104;+!Microsoft.Security#CA2122;+!Microsoft.Security#CA2114;+!Microsoft.Security#CA2123;+!Microsoft.Security#CA2111;+!Microsoft.Security#CA2108;+!Microsoft.Security#CA2107;+!Microsoft.Security#CA2103;+!Microsoft.Security#CA2118;+!Microsoft.Security#CA2109;+!Microsoft.Security#CA2119;+!Microsoft.Security#CA2106;+!Microsoft.Security#CA2112;+!Microsoft.Security#CA2120;+!Microsoft.Security#CA2121;+!Microsoft.Security#CA2126;+!Microsoft.Security#CA2124;+!Microsoft.Security#CA2127;+!Microsoft.Security#CA2128;+!Microsoft.Security#CA2129;+!Microsoft.Usage#CA2243;+!Microsoft.Usage#CA2236;+!Microsoft.Usage#CA1816;+!Microsoft.Usage#CA2227;+!Microsoft.Usage#CA2213;+!Microsoft.Usage#CA2216;+!Microsoft.Usage#CA2214;+!Microsoft.Usage#CA2222;+!Microsoft.Usage#CA1806;+!Microsoft.Usage#CA2217;+!Microsoft.Usage#CA2212;+!Microsoft.Usage#CA2219;+!Microsoft.Usage#CA2201;+!Microsoft.Usage#CA2228;+!Microsoft.Usage#CA2221;+!Microsoft.Usage#CA2220;+!Microsoft.Usage#CA2240;+!Microsoft.Usage#CA2229;+!Microsoft.Usage#CA2238;+!Microsoft.Usage#CA2207;+!Microsoft.Usage#CA2208;+!Microsoft.Usage#CA2235;+!Microsoft.Usage#CA2237;+!Microsoft.Usage#CA2232;+!Microsoft.Usage#CA2223;+!Microsoft.Usage#CA2211;+!Microsoft.Usage#CA2233;+!Microsoft.Usage#CA2225;+!Microsoft.Usage#CA2226;+!Microsoft.Usage#CA2231;+!Microsoft.Usage#CA2224;+!Microsoft.Usage#CA2218;+!Microsoft.Usage#CA2234;+!Microsoft.Usage#CA2239;+!Microsoft.Usage#CA2200;+!Microsoft.Usage#CA1801;+!Microsoft.Usage#CA2242;+!Microsoft.Usage#CA2205;+!Microsoft.Usage#CA2230</CodeAnalysisRules> - <NoWarn> - </NoWarn> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> - <DebugSymbols>true</DebugSymbols> - <DebugType>full</DebugType> - <Optimize>false</Optimize> -<OutputPath>$(SolutionDir)..\Bin\Debug\</OutputPath> -<DocumentationFile>$(OutputPath)\Microsoft.Scripting.Core.xml</DocumentationFile> - <DefineConstants>DEBUG;TRACE;$(SignedSym);CLR2</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <RunCodeAnalysis>false</RunCodeAnalysis> - <NoWarn> - </NoWarn> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> - <DebugType>pdbonly</DebugType> - <Optimize>true</Optimize> -<OutputPath>$(SolutionDir)..\Bin\Release\</OutputPath> -<DocumentationFile>$(OutputPath)\Microsoft.Scripting.Core.xml</DocumentationFile> - <DefineConstants>TRACE;$(SignedSym);CLR2</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <RunCodeAnalysis>false</RunCodeAnalysis> - <NoWarn> - </NoWarn> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight Debug|AnyCPU' "> - <DebugSymbols>true</DebugSymbols> -<OutputPath>$(SolutionDir)..\Bin\Silverlight Debug\</OutputPath> - <DefineConstants>TRACE;DEBUG;SILVERLIGHT;CLR2</DefineConstants> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <DebugType>full</DebugType> - <PlatformTarget>AnyCPU</PlatformTarget> - <RunCodeAnalysis>false</RunCodeAnalysis> - <ErrorReport>prompt</ErrorReport> - <NoStdLib>true</NoStdLib> -<DocumentationFile>$(OutputPath)\Microsoft.Scripting.Core.xml</DocumentationFile> - <NoWarn>618</NoWarn> - <SilverlightBuild>true</SilverlightBuild> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight Release|AnyCPU' "> -<OutputPath>$(SolutionDir)..\Bin\Silverlight Release\</OutputPath> - <DefineConstants>TRACE;SILVERLIGHT;CLR2</DefineConstants> -<DocumentationFile>$(OutputPath)\Microsoft.Scripting.Core.xml</DocumentationFile> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <NoWarn>618</NoWarn> - <NoStdLib>true</NoStdLib> - <DebugType>pdbonly</DebugType> - <PlatformTarget>AnyCPU</PlatformTarget> - <ErrorReport>prompt</ErrorReport> - <SilverlightBuild>true</SilverlightBuild> - </PropertyGroup> - <ItemGroup> - <Reference Include="System" Condition=" '$(SilverlightBuild)' != 'true' " /> - <Reference Include="System.Configuration" Condition=" '$(SilverlightBuild)' != 'true' " /> - <Reference Include="mscorlib, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" Condition=" '$(SilverlightBuild)' == 'true' "> - <SpecificVersion>False</SpecificVersion> - <HintPath>$(SilverlightPath)\mscorlib.dll</HintPath> - </Reference> - <Reference Include="System, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" Condition=" '$(SilverlightBuild)' == 'true' "> - <SpecificVersion>False</SpecificVersion> - <HintPath>$(SilverlightPath)\System.dll</HintPath> - </Reference> - <Reference Include="System.Data" Condition=" '$(SilverlightBuild)' != 'true' " /> - <Reference Include="System.Xml" Condition=" '$(SilverlightBuild)' != 'true' " /> - </ItemGroup> - <ItemGroup> - <Compile Include="..\..\Hosts\Silverlight\SilverlightVersion.cs" Condition=" '$(SilverlightBuild)' == 'true' "> - <Link>Properties\SilverlightVersion.cs</Link> - </Compile> - <Compile Include="Actions\CallInfo.cs" /> - <Compile Include="Actions\CallSiteOps.cs" /> - <Compile Include="Actions\IInvokeOnGetBinder.cs" /> - <Compile Include="Actions\InvokeMemberBinder.cs" /> - <Compile Include="Actions\BinaryOperationBinder.cs" /> - <Compile Include="Actions\CallSite.cs" /> - <Compile Include="Actions\CallSiteBinder.cs" /> - <Compile Include="Actions\CallSiteHelpers.cs" /> - <Compile Include="Actions\ConvertBinder.cs" /> - <Compile Include="Actions\DeleteIndexBinder.cs" /> - <Compile Include="Actions\DynamicObject.cs" /> - <Compile Include="Actions\ExpandoObject.cs" /> - <Compile Include="Actions\ExpandoClass.cs" /> - <Compile Include="Actions\GetIndexBinder.cs" /> - <Compile Include="Actions\CreateInstanceBinder.cs" /> - <Compile Include="Actions\DeleteMemberBinder.cs" /> - <Compile Include="Actions\GetMemberBinder.cs" /> - <Compile Include="Actions\IDynamicMetaObjectProvider.cs" /> - <Compile Include="Actions\InvokeBinder.cs" /> - <Compile Include="Actions\DynamicMetaObject.cs" /> - <Compile Include="Actions\DynamicMetaObjectBinder.cs" /> - <Compile Include="Actions\BindingRestrictions.cs" /> - <Compile Include="Actions\RuleCache.cs" /> - <Compile Include="Actions\SetIndexBinder.cs" /> - <Compile Include="Actions\SetMemberBinder.cs" /> - <Compile Include="Ast\Expression.DebuggerProxy.cs" /> - <Compile Include="Ast\IArgumentProvider.cs" /> - <Compile Include="Ast\ListArgumentProvider.cs" /> - <Compile Include="Actions\UnaryOperationBinder.cs" /> - <Compile Include="Ast\ExpressionStringBuilder.cs" /> - <Compile Include="Compiler\BoundConstants.cs" /> - <Compile Include="Ast\DebugInfoExpression.cs" /> - <Compile Include="Ast\SymbolDocumentInfo.cs" /> - <Compile Include="Compiler\DelegateHelpers.cs" /> - <Compile Include="Compiler\DelegateHelpers.Generated.cs" /> - <Compile Include="Ast\GotoExpression.cs" /> - <Compile Include="Compiler\LabelInfo.cs" /> - <Compile Include="Compiler\AnalyzedTree.cs" /> - <Compile Include="Compiler\OffsetTrackingILGenerator.cs" /> - <Compile Include="Compiler\RuntimeVariableList.cs" /> - <Compile Include="Actions\UpdateDelegates.Generated.cs" /> - <Compile Include="Ast\DynamicExpression.cs" /> - <Compile Include="Ast\BinaryExpression.cs" /> - <Compile Include="Ast\BlockExpression.cs" /> - <Compile Include="Ast\CatchBlock.cs" /> - <Compile Include="Ast\ConditionalExpression.cs" /> - <Compile Include="Ast\ConstantExpression.cs" /> - <Compile Include="Ast\DefaultExpression.cs" /> - <Compile Include="Ast\ElementInit.cs" /> - <Compile Include="Ast\Expression.cs" /> - <Compile Include="Ast\ExpressionType.cs" /> - <Compile Include="Ast\IndexExpression.cs" /> - <Compile Include="Ast\InvocationExpression.cs" /> - <Compile Include="Ast\LabelTarget.cs" /> - <Compile Include="Ast\LabelExpression.cs" /> - <Compile Include="Ast\LambdaExpression.cs" /> - <Compile Include="Ast\ListInitExpression.cs" /> - <Compile Include="Ast\RuntimeVariablesExpression.cs" /> - <Compile Include="Ast\LoopExpression.cs" /> - <Compile Include="Ast\MemberAssignment.cs" /> - <Compile Include="Ast\MemberBinding.cs" /> - <Compile Include="Ast\MemberExpression.cs" /> - <Compile Include="Ast\MemberInitExpression.cs" /> - <Compile Include="Ast\MemberListBinding.cs" /> - <Compile Include="Ast\MemberMemberBinding.cs" /> - <Compile Include="Ast\MethodCallExpression.cs" /> - <Compile Include="Ast\NewArrayExpression.cs" /> - <Compile Include="Ast\NewExpression.cs" /> - <Compile Include="Ast\ParameterExpression.cs" /> - <Compile Include="Ast\SwitchCase.cs" /> - <Compile Include="Ast\SwitchExpression.cs" /> - <Compile Include="Ast\TryExpression.cs" /> - <Compile Include="Ast\TypeBinaryExpression.cs" /> - <Compile Include="Ast\TypeUtils.cs" /> - <Compile Include="Ast\UnaryExpression.cs" /> - <Compile Include="Compiler\Closure.cs" /> - <Compile Include="Compiler\CompilerScope.Storage.cs" /> - <Compile Include="Compiler\CompilerScope.cs" /> - <Compile Include="Compiler\ConstantCheck.cs" /> - <Compile Include="Compiler\ExpressionQuoter.cs" /> - <Compile Include="Ast\ExpressionVisitor.cs" /> - <Compile Include="Ast\DebugViewWriter.cs" /> - <Compile Include="Compiler\HoistedLocals.cs" /> - <Compile Include="Compiler\KeyedQueue.cs" /> - <Compile Include="Compiler\LambdaCompiler.Address.cs" /> - <Compile Include="Compiler\LambdaCompiler.Binary.cs" /> - <Compile Include="Compiler\LambdaCompiler.ControlFlow.cs" /> - <Compile Include="Compiler\LambdaCompiler.Expressions.cs" /> - <Compile Include="Compiler\LambdaCompiler.Generated.cs" /> - <Compile Include="Compiler\LambdaCompiler.Lambda.cs" /> - <Compile Include="Compiler\LambdaCompiler.Logical.cs" /> - <Compile Include="Compiler\LambdaCompiler.Statements.cs" /> - <Compile Include="Compiler\LambdaCompiler.Unary.cs" /> - <Compile Include="Compiler\LambdaCompiler.cs" /> - <Compile Include="Compiler\DebugInfoGenerator.cs" /> - <Compile Include="Compiler\Set.cs" /> - <Compile Include="Compiler\StackSpiller.Bindings.cs" /> - <Compile Include="Compiler\StackSpiller.Generated.cs" /> - <Compile Include="Compiler\StackSpiller.Temps.cs" /> - <Compile Include="Compiler\StackSpiller.cs" /> - <Compile Include="Compiler\SymbolDocumentGenerator.cs" /> - <Compile Include="Compiler\VariableBinder.cs" /> - <Compile Include="Compiler\AssemblyGen.cs" /> - <Compile Include="Compiler\ILGen.cs" /> - <Compile Include="GlobalSuppressions.cs" /> - <Compile Include="Properties\AssemblyInfo.cs" /> - <Compile Include="Utils\Action.cs" /> - <Compile Include="Utils\CacheDict.cs" /> - <Compile Include="Utils\CollectionExtensions.cs" /> - <Compile Include="Utils\ContractUtils.cs" /> - <Compile Include="Utils\ExceptionFactory.Generated.cs" /> - <Compile Include="Utils\Function.cs" /> - <Compile Include="Utils\Helpers.cs" /> - <Compile Include="Utils\IRuntimeVariables.cs" /> - <Compile Include="Utils\ReadOnlyCollectionBuilder.cs" /> - <Compile Include="Utils\ReadOnlyDictionary.cs" /> - <Compile Include="Utils\ReferenceEqualityComparer.cs" /> - <Compile Include="Utils\StrongBox.cs" /> - <Compile Include="Utils\TrueReadOnlyCollection.cs" /> - <Compile Include="Utils\TypeExtensions.cs" /> - <Compile Include="Stubs.cs" /> - </ItemGroup> - <ItemGroup> - <ProjectReference Include="Microsoft.Scripting.ExtensionAttribute.csproj"> - <Project>{8B0F1074-750E-4D64-BF23-A1E0F54261E5}</Project> - <Name>Microsoft.Scripting.ExtensionAttribute</Name> - </ProjectReference> - </ItemGroup> - <ItemGroup> - <Content Include="..\..\System\Linq\Expressions\System.Linq.Expressions.txt"> - <Link>Ast\System.Linq.Expressions.txt</Link> - </Content> - </ItemGroup> - <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" Condition=" '$(SilverlightTreeBuild)' != 'true' " /> - <!-- This task produces a list of Compile items. --> - <Target Name="GetCompileItems" Outputs="@(CompileItems)"> - <CreateItem Include="%(Compile.Identity)"> - <Output TaskParameter="Include" ItemName="CompileItems" /> - </CreateItem> - </Target> -</Project> +<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
+ <Import Project="$(SolutionDir)..\Solutions\Common.proj" />
+
+ <PropertyGroup>
+ <Configuration Condition=" '$(Configuration)' == '' ">v2Debug</Configuration>
+ <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
+ <ProductVersion>10.0.20624</ProductVersion>
+ <SchemaVersion>2.0</SchemaVersion>
+ <ProjectGuid>{2AE75F5A-CD1F-4925-9647-AF4D1C282FB4}</ProjectGuid>
+ <OutputType>Library</OutputType>
+ <AppDesignerFolder>Properties</AppDesignerFolder>
+ <RootNamespace>System.Scripting</RootNamespace>
+ <AssemblyName>Microsoft.Scripting.Core</AssemblyName>
+ <DocumentationFile>$(SolutionDir)..\bin\$(Configuration)\Microsoft.Scripting.Core.XML</DocumentationFile>
+ <TreatWarningsAsErrors>true</TreatWarningsAsErrors>
+ <WarningsNotAsErrors>618</WarningsNotAsErrors>
+ <NoWarn>1591</NoWarn>
+ <BaseAddress>855638016</BaseAddress>
+ <CodeAnalysisRuleSet>Microsoft.Scripting.Core.ruleset</CodeAnalysisRuleSet>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'FxCop|AnyCPU' ">
+ <DebugType>pdbonly</DebugType>
+ <Optimize>true</Optimize>
+ <OutputPath>$(SolutionDir)..\bin\FxCop</OutputPath>
+ <DefineConstants>TRACE;$(SignedSym);CLR2</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <RunCodeAnalysis>true</RunCodeAnalysis>
+ <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'v2Debug|AnyCPU' ">
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>full</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>$(SolutionDir)..\bin\v2Debug</OutputPath>
+ <DefineConstants>DEBUG;TRACE;$(SignedSym);CLR2</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <RunCodeAnalysis>false</RunCodeAnalysis>
+ <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'v2Release|AnyCPU' ">
+ <DebugType>pdbonly</DebugType>
+ <Optimize>true</Optimize>
+ <OutputPath>$(SolutionDir)..\bin\v2Release</OutputPath>
+ <DefineConstants>TRACE;$(SignedSym);CLR2</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <RunCodeAnalysis>false</RunCodeAnalysis>
+ <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight3Debug|AnyCPU' ">
+ <DebugSymbols>true</DebugSymbols>
+ <OutputPath>$(SolutionDir)..\bin\Silverlight3Debug</OutputPath>
+ <DefineConstants>TRACE;DEBUG;SILVERLIGHT;CLR2</DefineConstants>
+ <DebugType>full</DebugType>
+ <PlatformTarget>AnyCPU</PlatformTarget>
+ <RunCodeAnalysis>false</RunCodeAnalysis>
+ <ErrorReport>prompt</ErrorReport>
+ <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight3Release|AnyCPU' ">
+ <OutputPath>$(SolutionDir)..\bin\Silverlight3Release</OutputPath>
+ <DefineConstants>TRACE;SILVERLIGHT;CLR2</DefineConstants>
+ <DebugType>pdbonly</DebugType>
+ <PlatformTarget>AnyCPU</PlatformTarget>
+ <ErrorReport>prompt</ErrorReport>
+ <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
+ </PropertyGroup>
+ <ItemGroup>
+ <Compile Include="..\..\Hosts\Silverlight\SilverlightVersion.cs" Condition=" '$(SilverlightBuild)' == 'true' ">
+ <Link>Properties\SilverlightVersion.cs</Link>
+ </Compile>
+ <Compile Include="Actions\CallInfo.cs" />
+ <Compile Include="Actions\CallSiteOps.cs" />
+ <Compile Include="Actions\IInvokeOnGetBinder.cs" />
+ <Compile Include="Actions\InvokeMemberBinder.cs" />
+ <Compile Include="Actions\BinaryOperationBinder.cs" />
+ <Compile Include="Actions\CallSite.cs" />
+ <Compile Include="Actions\CallSiteBinder.cs" />
+ <Compile Include="Actions\CallSiteHelpers.cs" />
+ <Compile Include="Actions\ConvertBinder.cs" />
+ <Compile Include="Actions\DeleteIndexBinder.cs" />
+ <Compile Include="Actions\DynamicObject.cs" />
+ <Compile Include="Actions\ExpandoObject.cs" />
+ <Compile Include="Actions\ExpandoClass.cs" />
+ <Compile Include="Actions\GetIndexBinder.cs" />
+ <Compile Include="Actions\CreateInstanceBinder.cs" />
+ <Compile Include="Actions\DeleteMemberBinder.cs" />
+ <Compile Include="Actions\GetMemberBinder.cs" />
+ <Compile Include="Actions\IDynamicMetaObjectProvider.cs" />
+ <Compile Include="Actions\InvokeBinder.cs" />
+ <Compile Include="Actions\DynamicMetaObject.cs" />
+ <Compile Include="Actions\DynamicMetaObjectBinder.cs" />
+ <Compile Include="Actions\BindingRestrictions.cs" />
+ <Compile Include="Actions\RuleCache.cs" />
+ <Compile Include="Actions\SetIndexBinder.cs" />
+ <Compile Include="Actions\SetMemberBinder.cs" />
+ <Compile Include="Ast\Expression.DebuggerProxy.cs" />
+ <Compile Include="Ast\IArgumentProvider.cs" />
+ <Compile Include="Ast\ListArgumentProvider.cs" />
+ <Compile Include="Actions\UnaryOperationBinder.cs" />
+ <Compile Include="Ast\ExpressionStringBuilder.cs" />
+ <Compile Include="Compiler\BoundConstants.cs" />
+ <Compile Include="Ast\DebugInfoExpression.cs" />
+ <Compile Include="Ast\SymbolDocumentInfo.cs" />
+ <Compile Include="Compiler\DelegateHelpers.cs" />
+ <Compile Include="Compiler\DelegateHelpers.Generated.cs" />
+ <Compile Include="Ast\GotoExpression.cs" />
+ <Compile Include="Compiler\LabelInfo.cs" />
+ <Compile Include="Compiler\AnalyzedTree.cs" />
+ <Compile Include="Compiler\OffsetTrackingILGenerator.cs" />
+ <Compile Include="Compiler\RuntimeVariableList.cs" />
+ <Compile Include="Actions\UpdateDelegates.Generated.cs" />
+ <Compile Include="Ast\DynamicExpression.cs" />
+ <Compile Include="Ast\BinaryExpression.cs" />
+ <Compile Include="Ast\BlockExpression.cs" />
+ <Compile Include="Ast\CatchBlock.cs" />
+ <Compile Include="Ast\ConditionalExpression.cs" />
+ <Compile Include="Ast\ConstantExpression.cs" />
+ <Compile Include="Ast\DefaultExpression.cs" />
+ <Compile Include="Ast\ElementInit.cs" />
+ <Compile Include="Ast\Expression.cs" />
+ <Compile Include="Ast\ExpressionType.cs" />
+ <Compile Include="Ast\IndexExpression.cs" />
+ <Compile Include="Ast\InvocationExpression.cs" />
+ <Compile Include="Ast\LabelTarget.cs" />
+ <Compile Include="Ast\LabelExpression.cs" />
+ <Compile Include="Ast\LambdaExpression.cs" />
+ <Compile Include="Ast\ListInitExpression.cs" />
+ <Compile Include="Ast\RuntimeVariablesExpression.cs" />
+ <Compile Include="Ast\LoopExpression.cs" />
+ <Compile Include="Ast\MemberAssignment.cs" />
+ <Compile Include="Ast\MemberBinding.cs" />
+ <Compile Include="Ast\MemberExpression.cs" />
+ <Compile Include="Ast\MemberInitExpression.cs" />
+ <Compile Include="Ast\MemberListBinding.cs" />
+ <Compile Include="Ast\MemberMemberBinding.cs" />
+ <Compile Include="Ast\MethodCallExpression.cs" />
+ <Compile Include="Ast\NewArrayExpression.cs" />
+ <Compile Include="Ast\NewExpression.cs" />
+ <Compile Include="Ast\ParameterExpression.cs" />
+ <Compile Include="Ast\SwitchCase.cs" />
+ <Compile Include="Ast\SwitchExpression.cs" />
+ <Compile Include="Ast\TryExpression.cs" />
+ <Compile Include="Ast\TypeBinaryExpression.cs" />
+ <Compile Include="Ast\TypeUtils.cs" />
+ <Compile Include="Ast\UnaryExpression.cs" />
+ <Compile Include="Compiler\Closure.cs" />
+ <Compile Include="Compiler\CompilerScope.Storage.cs" />
+ <Compile Include="Compiler\CompilerScope.cs" />
+ <Compile Include="Compiler\ConstantCheck.cs" />
+ <Compile Include="Compiler\ExpressionQuoter.cs" />
+ <Compile Include="Ast\ExpressionVisitor.cs" />
+ <Compile Include="Ast\DebugViewWriter.cs" />
+ <Compile Include="Compiler\HoistedLocals.cs" />
+ <Compile Include="Compiler\KeyedQueue.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Address.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Binary.cs" />
+ <Compile Include="Compiler\LambdaCompiler.ControlFlow.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Expressions.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Generated.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Lambda.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Logical.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Statements.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Unary.cs" />
+ <Compile Include="Compiler\LambdaCompiler.cs" />
+ <Compile Include="Compiler\DebugInfoGenerator.cs" />
+ <Compile Include="Compiler\Set.cs" />
+ <Compile Include="Compiler\StackSpiller.Bindings.cs" />
+ <Compile Include="Compiler\StackSpiller.Generated.cs" />
+ <Compile Include="Compiler\StackSpiller.Temps.cs" />
+ <Compile Include="Compiler\StackSpiller.cs" />
+ <Compile Include="Compiler\SymbolDocumentGenerator.cs" />
+ <Compile Include="Compiler\VariableBinder.cs" />
+ <Compile Include="Compiler\AssemblyGen.cs" />
+ <Compile Include="Compiler\ILGen.cs" />
+ <Compile Include="GlobalSuppressions.cs" />
+ <Compile Include="Properties\AssemblyInfo.cs" />
+ <Compile Include="Utils\Action.cs" />
+ <Compile Include="Utils\CacheDict.cs" />
+ <Compile Include="Utils\CollectionExtensions.cs" />
+ <Compile Include="Utils\ContractUtils.cs" />
+ <Compile Include="Utils\ExceptionFactory.Generated.cs" />
+ <Compile Include="Utils\Function.cs" />
+ <Compile Include="Utils\Helpers.cs" />
+ <Compile Include="Utils\IRuntimeVariables.cs" />
+ <Compile Include="Utils\ReadOnlyCollectionBuilder.cs" />
+ <Compile Include="Utils\ReadOnlyDictionary.cs" />
+ <Compile Include="Utils\ReferenceEqualityComparer.cs" />
+ <Compile Include="Utils\TrueReadOnlyCollection.cs" />
+ <Compile Include="Utils\TypeExtensions.cs" />
+ <Compile Include="Stubs.cs" />
+ </ItemGroup>
+ <ItemGroup>
+ <Content Include="..\..\System\Linq\Expressions\System.Linq.Expressions.txt">
+ <Link>Ast\System.Linq.Expressions.txt</Link>
+ </Content>
+ </ItemGroup>
+ <ItemGroup>
+ <None Include="Microsoft.Scripting.Core.ruleset" />
+ </ItemGroup>
+ <ItemGroup Condition=" '$(SilverlightBuild)' != 'true' ">
+ <Reference Include="System" />
+ <Reference Include="System.Configuration" />
+ <Reference Include="System.Core" />
+ </ItemGroup>
+ <ItemGroup Condition=" '$(SilverlightBuild)' == 'true' ">
+ <Reference Include="mscorlib, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e">
+ <HintPath>$(SilverlightPath)\mscorlib.dll</HintPath>
+ </Reference>
+ <Reference Include="System, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e">
+ <HintPath>$(SilverlightPath)\System.dll</HintPath>
+ </Reference>
+ <Reference Include="System.Core, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e">
+ <HintPath>$(SilverlightPath)\System.Core.dll</HintPath>
+ </Reference>
+ </ItemGroup>
+ <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" Condition=" '$(SilverlightTreeBuild)' != 'true' " />
+ <!-- This task produces a list of Compile items. -->
+ <Target Name="GetCompileItems" Outputs="@(CompileItems)">
+ <CreateItem Include="%(Compile.Identity)">
+ <Output TaskParameter="Include" ItemName="CompileItems" />
+ </CreateItem>
+ </Target>
+</Project>
diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Properties/AssemblyInfo.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Properties/AssemblyInfo.cs index 16f747334d1..97fd02fdc0b 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Properties/AssemblyInfo.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Properties/AssemblyInfo.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -27,7 +27,7 @@ using System.Security; [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("Microsoft")] [assembly: AssemblyProduct("Microsoft.Scripting")] -[assembly: AssemblyCopyright("� Microsoft Corporation. All rights reserved.")] +[assembly: AssemblyCopyright("© Microsoft Corporation. All rights reserved.")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] @@ -55,8 +55,8 @@ using System.Security; [assembly: System.Resources.NeutralResourcesLanguage("en-US")] #if !SILVERLIGHT -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.1.00")] -[assembly: AssemblyInformationalVersion("1.0.1")] +[assembly: AssemblyVersion("1.1.0.10")] +[assembly: AssemblyFileVersion("1.1.0.10")] +[assembly: AssemblyInformationalVersion("1.1")] [assembly: AllowPartiallyTrustedCallers] #endif diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Stubs.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Stubs.cs index ff81f806d87..b8e796f54fb 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Stubs.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Stubs.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/System.Core.csproj b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/System.Core.csproj index 79eebfbd561..87e0f80b87d 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/System.Core.csproj +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/System.Core.csproj @@ -1,246 +1,245 @@ -<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0"> - - - - - <PropertyGroup> - <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> - <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> - <ProductVersion>10.0.20624</ProductVersion> - <SchemaVersion>2.0</SchemaVersion> - <ProjectGuid>{2AE75F5A-CD1F-4925-9647-AF4D1C282FB4}</ProjectGuid> - <OutputType>Library</OutputType> - <AppDesignerFolder>Properties</AppDesignerFolder> - <RootNamespace>System.Scripting</RootNamespace> - <AssemblyName>System.Core</AssemblyName> -<DocumentationFile>$(OutputPath)\System.Core.XML</DocumentationFile> - <NoWarn>1591</NoWarn> - <OldToolsVersion>2.0</OldToolsVersion> -<AssemblyOriginatorKeyFile>$(SolutionDir)Runtime\MSSharedLibKey.snk</AssemblyOriginatorKeyFile> - <SignAssembly Condition="'$(SignAssembly)' == '' And Exists('$(AssemblyOriginatorKeyFile)')">true</SignAssembly> - <SignedSym Condition="'$(SignAssembly)' == 'true'">SIGNED</SignedSym> - <DelaySign>true</DelaySign> - <BaseAddress>855638016</BaseAddress> - <TargetFrameworkVersion>v4.0</TargetFrameworkVersion> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'FxCop|AnyCPU' "> - <DebugType>pdbonly</DebugType> - <Optimize>true</Optimize> -<OutputPath>$(SolutionDir)..\Bin\fxcop\</OutputPath> - <DefineConstants>TRACE;$(SignedSym)</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <RunCodeAnalysis>true</RunCodeAnalysis> - <CodeAnalysisRules>-Microsoft.Usage#CA2209;+!Microsoft.Design#CA1012;-!Microsoft.Design#CA2210;+!Microsoft.Design#CA1040;+!Microsoft.Design#CA1005;+!Microsoft.Design#CA1020;-!Microsoft.Design#CA1021;+!Microsoft.Design#CA1010;+!Microsoft.Design#CA1011;+!Microsoft.Design#CA1009;+!Microsoft.Design#CA1050;+!Microsoft.Design#CA1026;+!Microsoft.Design#CA1019;+!Microsoft.Design#CA1031;+!Microsoft.Design#CA1047;+!Microsoft.Design#CA1000;+!Microsoft.Design#CA1048;+!Microsoft.Design#CA1051;+!Microsoft.Design#CA1002;+!Microsoft.Design#CA1061;+!Microsoft.Design#CA1006;+!Microsoft.Design#CA1046;+!Microsoft.Design#CA1045;+!Microsoft.Design#CA1065;+!Microsoft.Design#CA1038;+!Microsoft.Design#CA1008;+!Microsoft.Design#CA1028;+!Microsoft.Design#CA1064;-!Microsoft.Design#CA1004;+!Microsoft.Design#CA1035;+!Microsoft.Design#CA1063;+!Microsoft.Design#CA1032;+!Microsoft.Design#CA1023;+!Microsoft.Design#CA1033;+!Microsoft.Design#CA1039;+!Microsoft.Design#CA1016;+!Microsoft.Design#CA1014;+!Microsoft.Design#CA1017;+!Microsoft.Design#CA1018;+!Microsoft.Design#CA1027;+!Microsoft.Design#CA1059;+!Microsoft.Design#CA1060;+!Microsoft.Design#CA1034;+!Microsoft.Design#CA1013;+!Microsoft.Design#CA1036;+!Microsoft.Design#CA1044;+!Microsoft.Design#CA1041;+!Microsoft.Design#CA1025;+!Microsoft.Design#CA1052;+!Microsoft.Design#CA1053;+!Microsoft.Design#CA1057;+!Microsoft.Design#CA1058;+!Microsoft.Design#CA1001;+!Microsoft.Design#CA1049;+!Microsoft.Design#CA1054;+!Microsoft.Design#CA1056;+!Microsoft.Design#CA1055;+!Microsoft.Design#CA1030;+!Microsoft.Design#CA1003;+!Microsoft.Design#CA1007;+!Microsoft.Design#CA1043;+!Microsoft.Design#CA1024;+!Microsoft.Globalization#CA1301;+!Microsoft.Globalization#CA1302;+!Microsoft.Globalization#CA1308;+!Microsoft.Globalization#CA1306;+!Microsoft.Globalization#CA1304;+!Microsoft.Globalization#CA1305;+!Microsoft.Globalization#CA2101;+!Microsoft.Globalization#CA1300;+!Microsoft.Globalization#CA1307;+!Microsoft.Globalization#CA1309;+!Microsoft.Interoperability#CA1403;+!Microsoft.Interoperability#CA1406;+!Microsoft.Interoperability#CA1413;+!Microsoft.Interoperability#CA1402;+!Microsoft.Interoperability#CA1407;+!Microsoft.Interoperability#CA1404;+!Microsoft.Interoperability#CA1410;+!Microsoft.Interoperability#CA1411;+!Microsoft.Interoperability#CA1405;+!Microsoft.Interoperability#CA1409;+!Microsoft.Interoperability#CA1415;+!Microsoft.Interoperability#CA1408;+!Microsoft.Interoperability#CA1414;+!Microsoft.Interoperability#CA1412;+!Microsoft.Interoperability#CA1400;+!Microsoft.Interoperability#CA1401;+!Microsoft.Maintainability#CA1506;+!Microsoft.Maintainability#CA1502;+!Microsoft.Maintainability#CA1501;+!Microsoft.Maintainability#CA1505;+!Microsoft.Maintainability#CA1504;+!Microsoft.Maintainability#CA1500;+!Microsoft.Mobility#CA1600;+!Microsoft.Mobility#CA1601;-!Microsoft.Naming#CA1702;+!Microsoft.Naming#CA1700;+!Microsoft.Naming#CA1712;+!Microsoft.Naming#CA1713;+!Microsoft.Naming#CA1714;+!Microsoft.Naming#CA1709;-!Microsoft.Naming#CA1704;+!Microsoft.Naming#CA1708;+!Microsoft.Naming#CA1715;-!Microsoft.Naming#CA1710;-!Microsoft.Naming#CA1720;+!Microsoft.Naming#CA1707;+!Microsoft.Naming#CA1722;-!Microsoft.Naming#CA1711;+!Microsoft.Naming#CA1716;+!Microsoft.Naming#CA1717;+!Microsoft.Naming#CA1725;+!Microsoft.Naming#CA1719;+!Microsoft.Naming#CA1721;+!Microsoft.Naming#CA1701;+!Microsoft.Naming#CA1703;+!Microsoft.Naming#CA1724;-!Microsoft.Naming#CA1726;+!Microsoft.Performance#CA1809;+!Microsoft.Performance#CA1811;+!Microsoft.Performance#CA1812;+!Microsoft.Performance#CA1813;+!Microsoft.Performance#CA1823;+!Microsoft.Performance#CA1800;+!Microsoft.Performance#CA1805;+!Microsoft.Performance#CA1810;+!Microsoft.Performance#CA1824;+!Microsoft.Performance#CA1822;+!Microsoft.Performance#CA1815;+!Microsoft.Performance#CA1814;+!Microsoft.Performance#CA1819;+!Microsoft.Performance#CA1821;+!Microsoft.Performance#CA1804;+!Microsoft.Performance#CA1820;+!Microsoft.Performance#CA1802;+!Microsoft.Portability#CA1901;+!Microsoft.Portability#CA1900;+!Microsoft.Reliability#CA2001;+!Microsoft.Reliability#CA2002;+!Microsoft.Reliability#CA2003;+!Microsoft.Reliability#CA2004;+!Microsoft.Reliability#CA2006;+!Microsoft.Security#CA2116;+!Microsoft.Security#CA2117;+!Microsoft.Security#CA2105;+!Microsoft.Security#CA2115;+!Microsoft.Security#CA2102;+!Microsoft.Security#CA2104;+!Microsoft.Security#CA2122;+!Microsoft.Security#CA2114;+!Microsoft.Security#CA2123;+!Microsoft.Security#CA2111;+!Microsoft.Security#CA2108;+!Microsoft.Security#CA2107;+!Microsoft.Security#CA2103;+!Microsoft.Security#CA2118;+!Microsoft.Security#CA2109;+!Microsoft.Security#CA2119;+!Microsoft.Security#CA2106;+!Microsoft.Security#CA2112;+!Microsoft.Security#CA2120;+!Microsoft.Security#CA2121;+!Microsoft.Security#CA2126;+!Microsoft.Security#CA2124;+!Microsoft.Security#CA2127;+!Microsoft.Security#CA2128;+!Microsoft.Security#CA2129;+!Microsoft.Usage#CA2243;+!Microsoft.Usage#CA2236;+!Microsoft.Usage#CA1816;+!Microsoft.Usage#CA2227;+!Microsoft.Usage#CA2213;+!Microsoft.Usage#CA2216;+!Microsoft.Usage#CA2214;+!Microsoft.Usage#CA2222;+!Microsoft.Usage#CA1806;+!Microsoft.Usage#CA2217;+!Microsoft.Usage#CA2212;+!Microsoft.Usage#CA2219;+!Microsoft.Usage#CA2201;+!Microsoft.Usage#CA2228;+!Microsoft.Usage#CA2221;+!Microsoft.Usage#CA2220;+!Microsoft.Usage#CA2240;+!Microsoft.Usage#CA2229;+!Microsoft.Usage#CA2238;+!Microsoft.Usage#CA2207;+!Microsoft.Usage#CA2208;+!Microsoft.Usage#CA2235;+!Microsoft.Usage#CA2237;+!Microsoft.Usage#CA2232;+!Microsoft.Usage#CA2223;+!Microsoft.Usage#CA2211;+!Microsoft.Usage#CA2233;+!Microsoft.Usage#CA2225;+!Microsoft.Usage#CA2226;+!Microsoft.Usage#CA2231;+!Microsoft.Usage#CA2224;+!Microsoft.Usage#CA2218;+!Microsoft.Usage#CA2234;+!Microsoft.Usage#CA2239;+!Microsoft.Usage#CA2200;+!Microsoft.Usage#CA1801;+!Microsoft.Usage#CA2242;+!Microsoft.Usage#CA2205;+!Microsoft.Usage#CA2230</CodeAnalysisRules> - <NoWarn> - </NoWarn> - <TargetFrameworkVersion>v4.0</TargetFrameworkVersion> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> - <DebugSymbols>true</DebugSymbols> - <DebugType>full</DebugType> - <Optimize>false</Optimize> -<OutputPath>$(SolutionDir)..\Bin\Debug\</OutputPath> -<DocumentationFile>$(OutputPath)\System.Core.xml</DocumentationFile> - <DefineConstants>DEBUG;TRACE;$(SignedSym)</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <RunCodeAnalysis>false</RunCodeAnalysis> - <NoWarn> - </NoWarn> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> - <DebugType>pdbonly</DebugType> - <Optimize>true</Optimize> -<OutputPath>$(SolutionDir)..\Bin\Release\</OutputPath> -<DocumentationFile>$(OutputPath)\System.Scripting.Core.xml</DocumentationFile> - <DefineConstants>TRACE;$(SignedSym)</DefineConstants> - <ErrorReport>prompt</ErrorReport> - <WarningLevel>4</WarningLevel> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <RunCodeAnalysis>false</RunCodeAnalysis> - <NoWarn> - </NoWarn> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight Debug|AnyCPU' "> - <DebugSymbols>true</DebugSymbols> -<OutputPath>$(SolutionDir)..\Bin\Silverlight Debug\</OutputPath> - <DefineConstants>TRACE;DEBUG;SILVERLIGHT</DefineConstants> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <DebugType>full</DebugType> - <PlatformTarget>AnyCPU</PlatformTarget> - <RunCodeAnalysis>false</RunCodeAnalysis> - <ErrorReport>prompt</ErrorReport> - <NoStdLib>true</NoStdLib> -<DocumentationFile>$(OutputPath)\System.Scripting.Core.xml</DocumentationFile> - <NoWarn>618</NoWarn> - <SilverlightBuild>true</SilverlightBuild> - <SilverlightSdkPath>$(ProgramFiles)\Microsoft Silverlight\2.0.31005.0</SilverlightSdkPath> - </PropertyGroup> - <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight Release|AnyCPU' "> -<OutputPath>$(SolutionDir)..\Bin\Silverlight Release\</OutputPath> - <DefineConstants>TRACE;SILVERLIGHT</DefineConstants> -<DocumentationFile>$(OutputPath)\System.Scripting.Core.xml</DocumentationFile> - <TreatWarningsAsErrors>true</TreatWarningsAsErrors> - <NoWarn>618</NoWarn> - <NoStdLib>true</NoStdLib> - <DebugType>pdbonly</DebugType> - <PlatformTarget>AnyCPU</PlatformTarget> - <ErrorReport>prompt</ErrorReport> - <SilverlightBuild>true</SilverlightBuild> - <SilverlightSdkPath>$(ProgramFiles)\Microsoft Silverlight\2.0.31005.0</SilverlightSdkPath> - </PropertyGroup> - <ItemGroup> - <Reference Include="System" Condition=" $(SilverlightBuild) != 'true' " /> - <Reference Include="System.Configuration" Condition=" $(SilverlightBuild) != 'true' " /> - <Reference Include="mscorlib, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" Condition=" '$(SilverlightBuild)' == 'true' "> - <SpecificVersion>False</SpecificVersion> - <HintPath>$(SilverlightSdkPath)\mscorlib.dll</HintPath> - </Reference> - <Reference Include="System, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" Condition=" '$(SilverlightBuild)' == 'true' "> - <SpecificVersion>False</SpecificVersion> - <HintPath>$(SilverlightSdkPath)\System.dll</HintPath> - </Reference> - <Reference Include="System.Data" Condition=" $(SilverlightBuild) != 'true' " /> - <Reference Include="System.Xml" Condition=" $(SilverlightBuild) != 'true' " /> - </ItemGroup> - <ItemGroup> - <Compile Include="..\..\Hosts\Silverlight\SilverlightVersion.cs" Condition=" '$(SilverlightBuild)' == 'true' "> - <Link>Properties\SilverlightVersion.cs</Link> - </Compile> - <Compile Include="Actions\CallInfo.cs" /> - <Compile Include="Actions\CallSiteOps.cs" /> - <Compile Include="Actions\InvokeMemberBinder.cs" /> - <Compile Include="Actions\BinaryOperationBinder.cs" /> - <Compile Include="Actions\CallSite.cs" /> - <Compile Include="Actions\CallSiteBinder.cs" /> - <Compile Include="Actions\CallSiteHelpers.cs" /> - <Compile Include="Actions\ConvertBinder.cs" /> - <Compile Include="Actions\DeleteIndexBinder.cs" /> - <Compile Include="Actions\DynamicObject.cs" /> - <Compile Include="Actions\ExpandoObject.cs" /> - <Compile Include="Actions\ExpandoClass.cs" /> - <Compile Include="Actions\GetIndexBinder.cs" /> - <Compile Include="Actions\CreateInstanceBinder.cs" /> - <Compile Include="Actions\DeleteMemberBinder.cs" /> - <Compile Include="Actions\GetMemberBinder.cs" /> - <Compile Include="Actions\IDynamicMetaObjectProvider.cs" /> - <Compile Include="Actions\InvokeBinder.cs" /> - <Compile Include="Actions\DynamicMetaObject.cs" /> - <Compile Include="Actions\DynamicMetaObjectBinder.cs" /> - <Compile Include="Actions\BindingRestrictions.cs" /> - <Compile Include="Actions\RuleCache.cs" /> - <Compile Include="Actions\SetIndexBinder.cs" /> - <Compile Include="Actions\SetMemberBinder.cs" /> - <Compile Include="Ast\Expression.DebuggerProxy.cs" /> - <Compile Include="Ast\IArgumentProvider.cs" /> - <Compile Include="Ast\ListArgumentProvider.cs" /> - <Compile Include="Actions\UnaryOperationBinder.cs" /> - <Compile Include="Ast\ExpressionStringBuilder.cs" /> - <Compile Include="Compiler\BoundConstants.cs" /> - <Compile Include="Ast\DebugInfoExpression.cs" /> - <Compile Include="Ast\SymbolDocumentInfo.cs" /> - <Compile Include="Compiler\DelegateHelpers.cs" /> - <Compile Include="Compiler\DelegateHelpers.Generated.cs" /> - <Compile Include="Ast\GotoExpression.cs" /> - <Compile Include="Compiler\LabelInfo.cs" /> - <Compile Include="Compiler\AnalyzedTree.cs" /> - <Compile Include="Compiler\OffsetTrackingILGenerator.cs" /> - <Compile Include="Compiler\RuntimeVariableList.cs" /> - <Compile Include="Actions\UpdateDelegates.Generated.cs" /> - <Compile Include="Ast\DynamicExpression.cs" /> - <Compile Include="Ast\BinaryExpression.cs" /> - <Compile Include="Ast\BlockExpression.cs" /> - <Compile Include="Ast\CatchBlock.cs" /> - <Compile Include="Ast\ConditionalExpression.cs" /> - <Compile Include="Ast\ConstantExpression.cs" /> - <Compile Include="Ast\DefaultExpression.cs" /> - <Compile Include="Ast\ElementInit.cs" /> - <Compile Include="Ast\Expression.cs" /> - <Compile Include="Ast\ExpressionType.cs" /> - <Compile Include="Ast\IndexExpression.cs" /> - <Compile Include="Ast\InvocationExpression.cs" /> - <Compile Include="Ast\LabelTarget.cs" /> - <Compile Include="Ast\LabelExpression.cs" /> - <Compile Include="Ast\LambdaExpression.cs" /> - <Compile Include="Ast\ListInitExpression.cs" /> - <Compile Include="Ast\RuntimeVariablesExpression.cs" /> - <Compile Include="Ast\LoopExpression.cs" /> - <Compile Include="Ast\MemberAssignment.cs" /> - <Compile Include="Ast\MemberBinding.cs" /> - <Compile Include="Ast\MemberExpression.cs" /> - <Compile Include="Ast\MemberInitExpression.cs" /> - <Compile Include="Ast\MemberListBinding.cs" /> - <Compile Include="Ast\MemberMemberBinding.cs" /> - <Compile Include="Ast\MethodCallExpression.cs" /> - <Compile Include="Ast\NewArrayExpression.cs" /> - <Compile Include="Ast\NewExpression.cs" /> - <Compile Include="Ast\ParameterExpression.cs" /> - <Compile Include="Ast\SwitchCase.cs" /> - <Compile Include="Ast\SwitchExpression.cs" /> - <Compile Include="Ast\TryExpression.cs" /> - <Compile Include="Ast\TypeBinaryExpression.cs" /> - <Compile Include="Ast\TypeUtils.cs" /> - <Compile Include="Ast\UnaryExpression.cs" /> - <Compile Include="Compiler\Closure.cs" /> - <Compile Include="Compiler\CompilerScope.Storage.cs" /> - <Compile Include="Compiler\CompilerScope.cs" /> - <Compile Include="Compiler\ConstantCheck.cs" /> - <Compile Include="Compiler\ExpressionQuoter.cs" /> - <Compile Include="Ast\ExpressionVisitor.cs" /> - <Compile Include="Ast\DebugViewWriter.cs" /> - <Compile Include="Compiler\HoistedLocals.cs" /> - <Compile Include="Compiler\KeyedQueue.cs" /> - <Compile Include="Compiler\LambdaCompiler.Address.cs" /> - <Compile Include="Compiler\LambdaCompiler.Binary.cs" /> - <Compile Include="Compiler\LambdaCompiler.ControlFlow.cs" /> - <Compile Include="Compiler\LambdaCompiler.Expressions.cs" /> - <Compile Include="Compiler\LambdaCompiler.Generated.cs" /> - <Compile Include="Compiler\LambdaCompiler.Lambda.cs" /> - <Compile Include="Compiler\LambdaCompiler.Logical.cs" /> - <Compile Include="Compiler\LambdaCompiler.Statements.cs" /> - <Compile Include="Compiler\LambdaCompiler.Unary.cs" /> - <Compile Include="Compiler\LambdaCompiler.cs" /> - <Compile Include="Compiler\DebugInfoGenerator.cs" /> - <Compile Include="Compiler\Set.cs" /> - <Compile Include="Compiler\StackSpiller.Bindings.cs" /> - <Compile Include="Compiler\StackSpiller.Generated.cs" /> - <Compile Include="Compiler\StackSpiller.Temps.cs" /> - <Compile Include="Compiler\StackSpiller.cs" /> - <Compile Include="Compiler\SymbolDocumentGenerator.cs" /> - <Compile Include="Compiler\VariableBinder.cs" /> - <Compile Include="Compiler\AssemblyGen.cs" /> - <Compile Include="Compiler\ILGen.cs" /> - <Compile Include="GlobalSuppressions.cs" /> - <Compile Include="Properties\AssemblyInfo.cs" /> - <Compile Include="Utils\Action.cs" /> - <Compile Include="Utils\CacheDict.cs" /> - <Compile Include="Utils\CollectionExtensions.cs" /> - <Compile Include="Utils\ContractUtils.cs" /> - <Compile Include="Utils\ExceptionFactory.Generated.cs" /> - <Compile Include="Utils\Function.cs" /> - <Compile Include="Utils\Helpers.cs" /> - <Compile Include="Utils\IRuntimeVariables.cs" /> - <Compile Include="Utils\ReadOnlyCollectionBuilder.cs" /> - <Compile Include="Utils\ReadOnlyDictionary.cs" /> - <Compile Include="Utils\ReferenceEqualityComparer.cs" /> - <Compile Include="Utils\StrongBox.cs" /> - <Compile Include="Utils\TrueReadOnlyCollection.cs" /> - <Compile Include="Utils\TypeExtensions.cs" /> - <Compile Include="Stubs.cs" /> - </ItemGroup> - <ItemGroup> - <Content Include="..\..\System\Linq\Expressions\System.Linq.Expressions.txt"> - <Link>Ast\System.Linq.Expressions.txt</Link> - </Content> - </ItemGroup> - <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" Condition=" '$(SilverlightTreeBuild)' != 'true' " /> - <!-- This task produces a list of Compile items. --> - <Target Name="GetCompileItems" Outputs="@(CompileItems)"> - <CreateItem Include="%(Compile.Identity)"> - <Output TaskParameter="Include" ItemName="CompileItems" /> - </CreateItem> - </Target> -</Project> +<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
+
+
+
+ <PropertyGroup>
+ <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
+ <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
+ <ProductVersion>10.0.20624</ProductVersion>
+ <SchemaVersion>2.0</SchemaVersion>
+ <ProjectGuid>{2AE75F5A-CD1F-4925-9647-AF4D1C282FB4}</ProjectGuid>
+ <OutputType>Library</OutputType>
+ <AppDesignerFolder>Properties</AppDesignerFolder>
+ <RootNamespace>System.Scripting</RootNamespace>
+ <AssemblyName>System.Core</AssemblyName>
+<DocumentationFile>$(OutputPath)\System.Core.XML</DocumentationFile>
+ <NoWarn>1591</NoWarn>
+ <OldToolsVersion>2.0</OldToolsVersion>
+ <AssemblyOriginatorKeyFile>$(SolutionDir)..\Internal\MSSharedLibKey.snk</AssemblyOriginatorKeyFile>
+ <SignAssembly Condition="'$(SignAssembly)' == '' And Exists('$(AssemblyOriginatorKeyFile)')">true</SignAssembly>
+ <SignedSym Condition="'$(SignAssembly)' == 'true'">SIGNED</SignedSym>
+ <DelaySign>true</DelaySign>
+ <BaseAddress>855638016</BaseAddress>
+ <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'FxCop|AnyCPU' ">
+ <DebugType>pdbonly</DebugType>
+ <Optimize>true</Optimize>
+<OutputPath>$(SolutionDir)..\bin\fxcop\</OutputPath>
+ <DefineConstants>TRACE;$(SignedSym)</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <TreatWarningsAsErrors>true</TreatWarningsAsErrors>
+ <RunCodeAnalysis>true</RunCodeAnalysis>
+ <CodeAnalysisRules>-Microsoft.Usage#CA2209;+!Microsoft.Design#CA1012;-!Microsoft.Design#CA2210;+!Microsoft.Design#CA1040;+!Microsoft.Design#CA1005;+!Microsoft.Design#CA1020;-!Microsoft.Design#CA1021;+!Microsoft.Design#CA1010;+!Microsoft.Design#CA1011;+!Microsoft.Design#CA1009;+!Microsoft.Design#CA1050;+!Microsoft.Design#CA1026;+!Microsoft.Design#CA1019;+!Microsoft.Design#CA1031;+!Microsoft.Design#CA1047;+!Microsoft.Design#CA1000;+!Microsoft.Design#CA1048;+!Microsoft.Design#CA1051;+!Microsoft.Design#CA1002;+!Microsoft.Design#CA1061;+!Microsoft.Design#CA1006;+!Microsoft.Design#CA1046;+!Microsoft.Design#CA1045;+!Microsoft.Design#CA1065;+!Microsoft.Design#CA1038;+!Microsoft.Design#CA1008;+!Microsoft.Design#CA1028;+!Microsoft.Design#CA1064;-!Microsoft.Design#CA1004;+!Microsoft.Design#CA1035;+!Microsoft.Design#CA1063;+!Microsoft.Design#CA1032;+!Microsoft.Design#CA1023;+!Microsoft.Design#CA1033;+!Microsoft.Design#CA1039;+!Microsoft.Design#CA1016;+!Microsoft.Design#CA1014;+!Microsoft.Design#CA1017;+!Microsoft.Design#CA1018;+!Microsoft.Design#CA1027;+!Microsoft.Design#CA1059;+!Microsoft.Design#CA1060;+!Microsoft.Design#CA1034;+!Microsoft.Design#CA1013;+!Microsoft.Design#CA1036;+!Microsoft.Design#CA1044;+!Microsoft.Design#CA1041;+!Microsoft.Design#CA1025;+!Microsoft.Design#CA1052;+!Microsoft.Design#CA1053;+!Microsoft.Design#CA1057;+!Microsoft.Design#CA1058;+!Microsoft.Design#CA1001;+!Microsoft.Design#CA1049;+!Microsoft.Design#CA1054;+!Microsoft.Design#CA1056;+!Microsoft.Design#CA1055;+!Microsoft.Design#CA1030;+!Microsoft.Design#CA1003;+!Microsoft.Design#CA1007;+!Microsoft.Design#CA1043;+!Microsoft.Design#CA1024;+!Microsoft.Globalization#CA1301;+!Microsoft.Globalization#CA1302;+!Microsoft.Globalization#CA1308;+!Microsoft.Globalization#CA1306;+!Microsoft.Globalization#CA1304;+!Microsoft.Globalization#CA1305;+!Microsoft.Globalization#CA2101;+!Microsoft.Globalization#CA1300;+!Microsoft.Globalization#CA1307;+!Microsoft.Globalization#CA1309;+!Microsoft.Interoperability#CA1403;+!Microsoft.Interoperability#CA1406;+!Microsoft.Interoperability#CA1413;+!Microsoft.Interoperability#CA1402;+!Microsoft.Interoperability#CA1407;+!Microsoft.Interoperability#CA1404;+!Microsoft.Interoperability#CA1410;+!Microsoft.Interoperability#CA1411;+!Microsoft.Interoperability#CA1405;+!Microsoft.Interoperability#CA1409;+!Microsoft.Interoperability#CA1415;+!Microsoft.Interoperability#CA1408;+!Microsoft.Interoperability#CA1414;+!Microsoft.Interoperability#CA1412;+!Microsoft.Interoperability#CA1400;+!Microsoft.Interoperability#CA1401;+!Microsoft.Maintainability#CA1506;+!Microsoft.Maintainability#CA1502;+!Microsoft.Maintainability#CA1501;+!Microsoft.Maintainability#CA1505;+!Microsoft.Maintainability#CA1504;+!Microsoft.Maintainability#CA1500;+!Microsoft.Mobility#CA1600;+!Microsoft.Mobility#CA1601;-!Microsoft.Naming#CA1702;+!Microsoft.Naming#CA1700;+!Microsoft.Naming#CA1712;+!Microsoft.Naming#CA1713;+!Microsoft.Naming#CA1714;+!Microsoft.Naming#CA1709;-!Microsoft.Naming#CA1704;+!Microsoft.Naming#CA1708;+!Microsoft.Naming#CA1715;-!Microsoft.Naming#CA1710;-!Microsoft.Naming#CA1720;+!Microsoft.Naming#CA1707;+!Microsoft.Naming#CA1722;-!Microsoft.Naming#CA1711;+!Microsoft.Naming#CA1716;+!Microsoft.Naming#CA1717;+!Microsoft.Naming#CA1725;+!Microsoft.Naming#CA1719;+!Microsoft.Naming#CA1721;+!Microsoft.Naming#CA1701;+!Microsoft.Naming#CA1703;+!Microsoft.Naming#CA1724;-!Microsoft.Naming#CA1726;+!Microsoft.Performance#CA1809;+!Microsoft.Performance#CA1811;+!Microsoft.Performance#CA1812;+!Microsoft.Performance#CA1813;+!Microsoft.Performance#CA1823;+!Microsoft.Performance#CA1800;+!Microsoft.Performance#CA1805;+!Microsoft.Performance#CA1810;+!Microsoft.Performance#CA1824;+!Microsoft.Performance#CA1822;+!Microsoft.Performance#CA1815;+!Microsoft.Performance#CA1814;+!Microsoft.Performance#CA1819;+!Microsoft.Performance#CA1821;+!Microsoft.Performance#CA1804;+!Microsoft.Performance#CA1820;+!Microsoft.Performance#CA1802;+!Microsoft.Portability#CA1901;+!Microsoft.Portability#CA1900;+!Microsoft.Reliability#CA2001;+!Microsoft.Reliability#CA2002;+!Microsoft.Reliability#CA2003;+!Microsoft.Reliability#CA2004;+!Microsoft.Reliability#CA2006;+!Microsoft.Security#CA2116;+!Microsoft.Security#CA2117;+!Microsoft.Security#CA2105;+!Microsoft.Security#CA2115;+!Microsoft.Security#CA2102;+!Microsoft.Security#CA2104;+!Microsoft.Security#CA2122;+!Microsoft.Security#CA2114;+!Microsoft.Security#CA2123;+!Microsoft.Security#CA2111;+!Microsoft.Security#CA2108;+!Microsoft.Security#CA2107;+!Microsoft.Security#CA2103;+!Microsoft.Security#CA2118;+!Microsoft.Security#CA2109;+!Microsoft.Security#CA2119;+!Microsoft.Security#CA2106;+!Microsoft.Security#CA2112;+!Microsoft.Security#CA2120;+!Microsoft.Security#CA2121;+!Microsoft.Security#CA2126;+!Microsoft.Security#CA2124;+!Microsoft.Security#CA2127;+!Microsoft.Security#CA2128;+!Microsoft.Security#CA2129;+!Microsoft.Usage#CA2243;+!Microsoft.Usage#CA2236;+!Microsoft.Usage#CA1816;+!Microsoft.Usage#CA2227;+!Microsoft.Usage#CA2213;+!Microsoft.Usage#CA2216;+!Microsoft.Usage#CA2214;+!Microsoft.Usage#CA2222;+!Microsoft.Usage#CA1806;+!Microsoft.Usage#CA2217;+!Microsoft.Usage#CA2212;+!Microsoft.Usage#CA2219;+!Microsoft.Usage#CA2201;+!Microsoft.Usage#CA2228;+!Microsoft.Usage#CA2221;+!Microsoft.Usage#CA2220;+!Microsoft.Usage#CA2240;+!Microsoft.Usage#CA2229;+!Microsoft.Usage#CA2238;+!Microsoft.Usage#CA2207;+!Microsoft.Usage#CA2208;+!Microsoft.Usage#CA2235;+!Microsoft.Usage#CA2237;+!Microsoft.Usage#CA2232;+!Microsoft.Usage#CA2223;+!Microsoft.Usage#CA2211;+!Microsoft.Usage#CA2233;+!Microsoft.Usage#CA2225;+!Microsoft.Usage#CA2226;+!Microsoft.Usage#CA2231;+!Microsoft.Usage#CA2224;+!Microsoft.Usage#CA2218;+!Microsoft.Usage#CA2234;+!Microsoft.Usage#CA2239;+!Microsoft.Usage#CA2200;+!Microsoft.Usage#CA1801;+!Microsoft.Usage#CA2242;+!Microsoft.Usage#CA2205;+!Microsoft.Usage#CA2230</CodeAnalysisRules>
+ <NoWarn>
+ </NoWarn>
+ <TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'v2Debug|AnyCPU' ">
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>full</DebugType>
+ <Optimize>false</Optimize>
+<OutputPath>$(SolutionDir)..\bin\v2Debug\</OutputPath>
+<DocumentationFile>$(OutputPath)\System.Core.xml</DocumentationFile>
+ <DefineConstants>DEBUG;TRACE;$(SignedSym)</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <TreatWarningsAsErrors>true</TreatWarningsAsErrors>
+ <RunCodeAnalysis>false</RunCodeAnalysis>
+ <NoWarn>
+ </NoWarn>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'v2Release|AnyCPU' ">
+ <DebugType>pdbonly</DebugType>
+ <Optimize>true</Optimize>
+<OutputPath>$(SolutionDir)..\Bin\v2Release\</OutputPath>
+<DocumentationFile>$(OutputPath)\System.Scripting.Core.xml</DocumentationFile>
+ <DefineConstants>TRACE;$(SignedSym)</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ <TreatWarningsAsErrors>true</TreatWarningsAsErrors>
+ <RunCodeAnalysis>false</RunCodeAnalysis>
+ <NoWarn>
+ </NoWarn>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight3Debug|AnyCPU' ">
+ <DebugSymbols>true</DebugSymbols>
+<OutputPath>$(SolutionDir)..\bin\Silverlight3Debug\</OutputPath>
+ <DefineConstants>TRACE;DEBUG;SILVERLIGHT</DefineConstants>
+ <TreatWarningsAsErrors>true</TreatWarningsAsErrors>
+ <DebugType>full</DebugType>
+ <PlatformTarget>AnyCPU</PlatformTarget>
+ <RunCodeAnalysis>false</RunCodeAnalysis>
+ <ErrorReport>prompt</ErrorReport>
+ <NoStdLib>true</NoStdLib>
+<DocumentationFile>$(OutputPath)\System.Scripting.Core.xml</DocumentationFile>
+ <NoWarn>618</NoWarn>
+ <SilverlightBuild>true</SilverlightBuild>
+ <SilverlightSdkPath>$(ProgramFiles)\Microsoft Silverlight\2.0.31005.0</SilverlightSdkPath>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Silverlight3Release|AnyCPU' ">
+<OutputPath>$(SolutionDir)..\bin\Silverlight3Release\</OutputPath>
+ <DefineConstants>TRACE;SILVERLIGHT</DefineConstants>
+<DocumentationFile>$(OutputPath)\System.Scripting.Core.xml</DocumentationFile>
+ <TreatWarningsAsErrors>true</TreatWarningsAsErrors>
+ <NoWarn>618</NoWarn>
+ <NoStdLib>true</NoStdLib>
+ <DebugType>pdbonly</DebugType>
+ <PlatformTarget>AnyCPU</PlatformTarget>
+ <ErrorReport>prompt</ErrorReport>
+ <SilverlightBuild>true</SilverlightBuild>
+ <SilverlightSdkPath>$(ProgramFiles)\Microsoft Silverlight\2.0.31005.0</SilverlightSdkPath>
+ </PropertyGroup>
+ <ItemGroup>
+ <Reference Include="System" Condition=" $(SilverlightBuild) != 'true' " />
+ <Reference Include="System.Configuration" Condition=" $(SilverlightBuild) != 'true' " />
+ <Reference Include="mscorlib, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" Condition=" '$(SilverlightBuild)' == 'true' ">
+ <SpecificVersion>False</SpecificVersion>
+ <HintPath>$(SilverlightSdkPath)\mscorlib.dll</HintPath>
+ </Reference>
+ <Reference Include="System, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e" Condition=" '$(SilverlightBuild)' == 'true' ">
+ <SpecificVersion>False</SpecificVersion>
+ <HintPath>$(SilverlightSdkPath)\System.dll</HintPath>
+ </Reference>
+ <Reference Include="System.Data" Condition=" $(SilverlightBuild) != 'true' " />
+ <Reference Include="System.Xml" Condition=" $(SilverlightBuild) != 'true' " />
+ </ItemGroup>
+ <ItemGroup>
+ <Compile Include="..\..\Hosts\Silverlight\SilverlightVersion.cs" Condition=" '$(SilverlightBuild)' == 'true' ">
+ <Link>Properties\SilverlightVersion.cs</Link>
+ </Compile>
+ <Compile Include="Actions\CallInfo.cs" />
+ <Compile Include="Actions\CallSiteOps.cs" />
+ <Compile Include="Actions\InvokeMemberBinder.cs" />
+ <Compile Include="Actions\BinaryOperationBinder.cs" />
+ <Compile Include="Actions\CallSite.cs" />
+ <Compile Include="Actions\CallSiteBinder.cs" />
+ <Compile Include="Actions\CallSiteHelpers.cs" />
+ <Compile Include="Actions\ConvertBinder.cs" />
+ <Compile Include="Actions\DeleteIndexBinder.cs" />
+ <Compile Include="Actions\DynamicObject.cs" />
+ <Compile Include="Actions\ExpandoObject.cs" />
+ <Compile Include="Actions\ExpandoClass.cs" />
+ <Compile Include="Actions\GetIndexBinder.cs" />
+ <Compile Include="Actions\CreateInstanceBinder.cs" />
+ <Compile Include="Actions\DeleteMemberBinder.cs" />
+ <Compile Include="Actions\GetMemberBinder.cs" />
+ <Compile Include="Actions\IDynamicMetaObjectProvider.cs" />
+ <Compile Include="Actions\InvokeBinder.cs" />
+ <Compile Include="Actions\DynamicMetaObject.cs" />
+ <Compile Include="Actions\DynamicMetaObjectBinder.cs" />
+ <Compile Include="Actions\BindingRestrictions.cs" />
+ <Compile Include="Actions\RuleCache.cs" />
+ <Compile Include="Actions\SetIndexBinder.cs" />
+ <Compile Include="Actions\SetMemberBinder.cs" />
+ <Compile Include="Ast\Expression.DebuggerProxy.cs" />
+ <Compile Include="Ast\IArgumentProvider.cs" />
+ <Compile Include="Ast\ListArgumentProvider.cs" />
+ <Compile Include="Actions\UnaryOperationBinder.cs" />
+ <Compile Include="Ast\ExpressionStringBuilder.cs" />
+ <Compile Include="Compiler\BoundConstants.cs" />
+ <Compile Include="Ast\DebugInfoExpression.cs" />
+ <Compile Include="Ast\SymbolDocumentInfo.cs" />
+ <Compile Include="Compiler\DelegateHelpers.cs" />
+ <Compile Include="Compiler\DelegateHelpers.Generated.cs" />
+ <Compile Include="Ast\GotoExpression.cs" />
+ <Compile Include="Compiler\LabelInfo.cs" />
+ <Compile Include="Compiler\AnalyzedTree.cs" />
+ <Compile Include="Compiler\OffsetTrackingILGenerator.cs" />
+ <Compile Include="Compiler\RuntimeVariableList.cs" />
+ <Compile Include="Actions\UpdateDelegates.Generated.cs" />
+ <Compile Include="Ast\DynamicExpression.cs" />
+ <Compile Include="Ast\BinaryExpression.cs" />
+ <Compile Include="Ast\BlockExpression.cs" />
+ <Compile Include="Ast\CatchBlock.cs" />
+ <Compile Include="Ast\ConditionalExpression.cs" />
+ <Compile Include="Ast\ConstantExpression.cs" />
+ <Compile Include="Ast\DefaultExpression.cs" />
+ <Compile Include="Ast\ElementInit.cs" />
+ <Compile Include="Ast\Expression.cs" />
+ <Compile Include="Ast\ExpressionType.cs" />
+ <Compile Include="Ast\IndexExpression.cs" />
+ <Compile Include="Ast\InvocationExpression.cs" />
+ <Compile Include="Ast\LabelTarget.cs" />
+ <Compile Include="Ast\LabelExpression.cs" />
+ <Compile Include="Ast\LambdaExpression.cs" />
+ <Compile Include="Ast\ListInitExpression.cs" />
+ <Compile Include="Ast\RuntimeVariablesExpression.cs" />
+ <Compile Include="Ast\LoopExpression.cs" />
+ <Compile Include="Ast\MemberAssignment.cs" />
+ <Compile Include="Ast\MemberBinding.cs" />
+ <Compile Include="Ast\MemberExpression.cs" />
+ <Compile Include="Ast\MemberInitExpression.cs" />
+ <Compile Include="Ast\MemberListBinding.cs" />
+ <Compile Include="Ast\MemberMemberBinding.cs" />
+ <Compile Include="Ast\MethodCallExpression.cs" />
+ <Compile Include="Ast\NewArrayExpression.cs" />
+ <Compile Include="Ast\NewExpression.cs" />
+ <Compile Include="Ast\ParameterExpression.cs" />
+ <Compile Include="Ast\SwitchCase.cs" />
+ <Compile Include="Ast\SwitchExpression.cs" />
+ <Compile Include="Ast\TryExpression.cs" />
+ <Compile Include="Ast\TypeBinaryExpression.cs" />
+ <Compile Include="Ast\TypeUtils.cs" />
+ <Compile Include="Ast\UnaryExpression.cs" />
+ <Compile Include="Compiler\Closure.cs" />
+ <Compile Include="Compiler\CompilerScope.Storage.cs" />
+ <Compile Include="Compiler\CompilerScope.cs" />
+ <Compile Include="Compiler\ConstantCheck.cs" />
+ <Compile Include="Compiler\ExpressionQuoter.cs" />
+ <Compile Include="Ast\ExpressionVisitor.cs" />
+ <Compile Include="Ast\DebugViewWriter.cs" />
+ <Compile Include="Compiler\HoistedLocals.cs" />
+ <Compile Include="Compiler\KeyedQueue.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Address.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Binary.cs" />
+ <Compile Include="Compiler\LambdaCompiler.ControlFlow.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Expressions.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Generated.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Lambda.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Logical.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Statements.cs" />
+ <Compile Include="Compiler\LambdaCompiler.Unary.cs" />
+ <Compile Include="Compiler\LambdaCompiler.cs" />
+ <Compile Include="Compiler\DebugInfoGenerator.cs" />
+ <Compile Include="Compiler\Set.cs" />
+ <Compile Include="Compiler\StackSpiller.Bindings.cs" />
+ <Compile Include="Compiler\StackSpiller.Generated.cs" />
+ <Compile Include="Compiler\StackSpiller.Temps.cs" />
+ <Compile Include="Compiler\StackSpiller.cs" />
+ <Compile Include="Compiler\SymbolDocumentGenerator.cs" />
+ <Compile Include="Compiler\VariableBinder.cs" />
+ <Compile Include="Compiler\AssemblyGen.cs" />
+ <Compile Include="Compiler\ILGen.cs" />
+ <Compile Include="GlobalSuppressions.cs" />
+ <Compile Include="Properties\AssemblyInfo.cs" />
+ <Compile Include="Utils\Action.cs" />
+ <Compile Include="Utils\CacheDict.cs" />
+ <Compile Include="Utils\CollectionExtensions.cs" />
+ <Compile Include="Utils\ContractUtils.cs" />
+ <Compile Include="Utils\ExceptionFactory.Generated.cs" />
+ <Compile Include="Utils\Function.cs" />
+ <Compile Include="Utils\Helpers.cs" />
+ <Compile Include="Utils\IRuntimeVariables.cs" />
+ <Compile Include="Utils\ReadOnlyCollectionBuilder.cs" />
+ <Compile Include="Utils\ReadOnlyDictionary.cs" />
+ <Compile Include="Utils\ReferenceEqualityComparer.cs" />
+ <Compile Include="Utils\StrongBox.cs" />
+ <Compile Include="Utils\TrueReadOnlyCollection.cs" />
+ <Compile Include="Utils\TypeExtensions.cs" />
+ <Compile Include="Stubs.cs" />
+ </ItemGroup>
+ <ItemGroup>
+ <Content Include="..\..\System\Linq\Expressions\System.Linq.Expressions.txt">
+ <Link>Ast\System.Linq.Expressions.txt</Link>
+ </Content>
+ </ItemGroup>
+ <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" Condition=" '$(SilverlightTreeBuild)' != 'true' " />
+ <!-- This task produces a list of Compile items. -->
+ <Target Name="GetCompileItems" Outputs="@(CompileItems)">
+ <CreateItem Include="%(Compile.Identity)">
+ <Output TaskParameter="Include" ItemName="CompileItems" />
+ </CreateItem>
+ </Target>
+</Project>
diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/Action.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/Action.cs index 17d41680a2c..9e7e53cf34d 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/Action.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/Action.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -19,17 +19,6 @@ namespace Microsoft.Scripting.Utils { namespace System { #endif -#if CLR2 || SILVERLIGHT - - /// <summary> - /// Encapsulates a method that takes no parameters and does not return a value. - /// </summary> - public delegate void Action(); - -#endif - - // public delegate void Action<T>(T obj); -- Already defined in mscorlib - #region Generated Action Types // *** BEGIN GENERATED CODE *** @@ -38,41 +27,6 @@ namespace System { #if CLR2 || SILVERLIGHT /// <summary> - /// Encapsulates a method that takes two parameters and does not return a value. - /// </summary> - /// <typeparam name="T1">The type of the first parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="T2">The type of the second parameter of the method that this delegate encapsulates.</typeparam> - /// <param name="arg1">The first parameter of the method that this delegate encapsulates.</param> - /// <param name="arg2">The second parameter of the method that this delegate encapsulates.</param> - public delegate void Action<T1, T2>(T1 arg1, T2 arg2); - - /// <summary> - /// Encapsulates a method that takes three parameters and does not return a value. - /// </summary> - /// <typeparam name="T1">The type of the first parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="T2">The type of the second parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="T3">The type of the third parameter of the method that this delegate encapsulates.</typeparam> - /// <param name="arg1">The first parameter of the method that this delegate encapsulates.</param> - /// <param name="arg2">The second parameter of the method that this delegate encapsulates.</param> - /// <param name="arg3">The third parameter of the method that this delegate encapsulates.</param> - [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1005:AvoidExcessiveParametersOnGenericTypes")] - public delegate void Action<T1, T2, T3>(T1 arg1, T2 arg2, T3 arg3); - - /// <summary> - /// Encapsulates a method that takes four parameters and does not return a value. - /// </summary> - /// <typeparam name="T1">The type of the first parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="T2">The type of the second parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="T3">The type of the third parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="T4">The type of the fourth parameter of the method that this delegate encapsulates.</typeparam> - /// <param name="arg1">The first parameter of the method that this delegate encapsulates.</param> - /// <param name="arg2">The second parameter of the method that this delegate encapsulates.</param> - /// <param name="arg3">The third parameter of the method that this delegate encapsulates.</param> - /// <param name="arg4">The fourth parameter of the method that this delegate encapsulates.</param> - [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1005:AvoidExcessiveParametersOnGenericTypes")] - public delegate void Action<T1, T2, T3, T4>(T1 arg1, T2 arg2, T3 arg3, T4 arg4); - - /// <summary> /// Encapsulates a method that takes five parameters and does not return a value. /// </summary> /// <typeparam name="T1">The type of the first parameter of the method that this delegate encapsulates.</typeparam> diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/CacheDict.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/CacheDict.cs index defacc1ff4d..1b94d705030 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/CacheDict.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/CacheDict.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/CollectionExtensions.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/CollectionExtensions.cs index 0eebded5f38..fd7ac36114d 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/CollectionExtensions.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/CollectionExtensions.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -15,8 +15,10 @@ #if CLR2 using Microsoft.Scripting.Utils; +using Microsoft.Scripting.Ast; #else using System.Diagnostics.Contracts; +using System.Linq.Expressions; #endif using System.Collections.Generic; @@ -41,6 +43,17 @@ namespace System.Dynamic.Utils { return EmptyReadOnlyCollection<T>.Instance; } +#if SILVERLIGHT + if (Expression.SilverlightQuirks) { + // Allow any ReadOnlyCollection to be stored directly + // (even though this is not safe) + var r = enumerable as ReadOnlyCollection<T>; + if (r != null) { + return r; + } + } +#endif + var troc = enumerable as TrueReadOnlyCollection<T>; if (troc != null) { return troc; diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ContractUtils.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ContractUtils.cs index 652ef4a671c..d8cc36be2bb 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ContractUtils.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ContractUtils.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ExceptionFactory.Generated.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ExceptionFactory.Generated.cs index 1a1054bf987..08454fa43df 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ExceptionFactory.Generated.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ExceptionFactory.Generated.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/Function.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/Function.cs index 62b6fbba950..143e6b32ec6 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/Function.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/Function.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -19,26 +19,6 @@ namespace Microsoft.Scripting.Utils { namespace System { #endif -#if CLR2 || SILVERLIGHT - - /// <summary> - /// Encapsulates a method that has no parameters and returns a value of the type specified by the TResult parameter. - /// </summary> - /// <typeparam name="TResult">The type of the return value of the method that this delegate encapsulates.</typeparam> - /// <returns>The return value of the method that this delegate encapsulates.</returns> - public delegate TResult Func<TResult>(); - - /// <summary> - /// Encapsulates a method that has one parameter and returns a value of the type specified by the TResult parameter. - /// </summary> - /// <typeparam name="T">The type of the first parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="TResult">The type of the return value of the method that this delegate encapsulates.</typeparam> - /// <param name="arg">The first parameter of the method that this delegate encapsulates.</param> - /// <returns>The return value of the method that this delegate encapsulates.</returns> - public delegate TResult Func<T, TResult>(T arg); - -#endif - #region Generated Func Types // *** BEGIN GENERATED CODE *** @@ -47,48 +27,6 @@ namespace System { #if CLR2 || SILVERLIGHT /// <summary> - /// Encapsulates a method that has two parameters and returns a value of the type specified by the TResult parameter. - /// </summary> - /// <typeparam name="T1">The type of the first parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="T2">The type of the second parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="TResult">The type of the return value of the method that this delegate encapsulates.</typeparam> - /// <param name="arg1">The first parameter of the method that this delegate encapsulates.</param> - /// <param name="arg2">The second parameter of the method that this delegate encapsulates.</param> - /// <returns>The return value of the method that this delegate encapsulates.</returns> - [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1005:AvoidExcessiveParametersOnGenericTypes")] - public delegate TResult Func<T1, T2, TResult>(T1 arg1, T2 arg2); - - /// <summary> - /// Encapsulates a method that has three parameters and returns a value of the type specified by the TResult parameter. - /// </summary> - /// <typeparam name="T1">The type of the first parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="T2">The type of the second parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="T3">The type of the third parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="TResult">The type of the return value of the method that this delegate encapsulates.</typeparam> - /// <param name="arg1">The first parameter of the method that this delegate encapsulates.</param> - /// <param name="arg2">The second parameter of the method that this delegate encapsulates.</param> - /// <param name="arg3">The third parameter of the method that this delegate encapsulates.</param> - /// <returns>The return value of the method that this delegate encapsulates.</returns> - [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1005:AvoidExcessiveParametersOnGenericTypes")] - public delegate TResult Func<T1, T2, T3, TResult>(T1 arg1, T2 arg2, T3 arg3); - - /// <summary> - /// Encapsulates a method that has four parameters and returns a value of the type specified by the TResult parameter. - /// </summary> - /// <typeparam name="T1">The type of the first parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="T2">The type of the second parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="T3">The type of the third parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="T4">The type of the fourth parameter of the method that this delegate encapsulates.</typeparam> - /// <typeparam name="TResult">The type of the return value of the method that this delegate encapsulates.</typeparam> - /// <param name="arg1">The first parameter of the method that this delegate encapsulates.</param> - /// <param name="arg2">The second parameter of the method that this delegate encapsulates.</param> - /// <param name="arg3">The third parameter of the method that this delegate encapsulates.</param> - /// <param name="arg4">The fourth parameter of the method that this delegate encapsulates.</param> - /// <returns>The return value of the method that this delegate encapsulates.</returns> - [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1005:AvoidExcessiveParametersOnGenericTypes")] - public delegate TResult Func<T1, T2, T3, T4, TResult>(T1 arg1, T2 arg2, T3 arg3, T4 arg4); - - /// <summary> /// Encapsulates a method that has five parameters and returns a value of the type specified by the TResult parameter. /// </summary> /// <typeparam name="T1">The type of the first parameter of the method that this delegate encapsulates.</typeparam> diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/Helpers.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/Helpers.cs index 0444b69d82a..6f2cc98ffe2 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/Helpers.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/Helpers.cs @@ -3,11 +3,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/IRuntimeVariables.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/IRuntimeVariables.cs index 38d90d366da..8130a617d86 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/IRuntimeVariables.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/IRuntimeVariables.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ReadOnlyCollectionBuilder.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ReadOnlyCollectionBuilder.cs index 3626ea28bb5..2c272b81e72 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ReadOnlyCollectionBuilder.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ReadOnlyCollectionBuilder.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ReadOnlyDictionary.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ReadOnlyDictionary.cs index d8d3c39d872..1202e9db274 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ReadOnlyDictionary.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ReadOnlyDictionary.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ReferenceEqualityComparer.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ReferenceEqualityComparer.cs index e44676c9abd..fff90a5c6f0 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ReferenceEqualityComparer.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/ReferenceEqualityComparer.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/StrongBox.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/StrongBox.cs index bc6f7278763..baee2988755 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/StrongBox.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/StrongBox.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/TrueReadOnlyCollection.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/TrueReadOnlyCollection.cs index fd0157e577b..da9cf38ee0d 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/TrueReadOnlyCollection.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/TrueReadOnlyCollection.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * diff --git a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/TypeExtensions.cs b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/TypeExtensions.cs index 16995b9f1f5..fd0da9097b2 100644 --- a/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/TypeExtensions.cs +++ b/mcs/class/dlr/Runtime/Microsoft.Scripting.Core/Utils/TypeExtensions.cs @@ -2,11 +2,11 @@ * * Copyright (c) Microsoft Corporation. * - * This source code is subject to terms and conditions of the Microsoft Public License. A + * This source code is subject to terms and conditions of the Apache License, Version 2.0. A * copy of the license can be found in the License.html file at the root of this distribution. If - * you cannot locate the Microsoft Public License, please send an email to + * you cannot locate the Apache License, Version 2.0, please send an email to * dlr@microsoft.com. By using this source code in any fashion, you are agreeing to be bound - * by the terms of the Microsoft Public License. + * by the terms of the Apache License, Version 2.0. * * You must not remove this notice, or any other, from this software. * @@ -24,20 +24,6 @@ namespace System.Dynamic.Utils { internal static class TypeExtensions { /// <summary> - /// Creates an open delegate for the given (dynamic)method. - /// </summary> - internal static Delegate CreateDelegate(this MethodInfo methodInfo, Type delegateType) { - Debug.Assert(methodInfo != null && delegateType != null); - - var dm = methodInfo as DynamicMethod; - if (dm != null) { - return dm.CreateDelegate(delegateType); - } else { - return Delegate.CreateDelegate(delegateType, methodInfo); - } - } - - /// <summary> /// Creates a closed delegate for the given (dynamic)method. /// </summary> internal static Delegate CreateDelegate(this MethodInfo methodInfo, Type delegateType, object target) { diff --git a/mcs/class/dlr/sync.sh b/mcs/class/dlr/sync.sh index fe3554f2e7a..7a84ed56b96 100755 --- a/mcs/class/dlr/sync.sh +++ b/mcs/class/dlr/sync.sh @@ -1,2 +1,2 @@ -rsync -r /home/marek/svn/dlr/svn/DLR_Main/Src/Runtime/Microsoft.Dynamic/ Runtime/Microsoft.Dynamic --exclude=".*/" --exclude="*.snk" -rsync -r /home/marek/svn/dlr/svn/DLR_Main/Src/Runtime/Microsoft.Scripting.Core/ Runtime/Microsoft.Scripting.Core --exclude=".*/" --exclude="*.snk" +rsync -r /home/marek/svn/dlr/svn/DLR_Main/Runtime/Microsoft.Dynamic/ Runtime/Microsoft.Dynamic --exclude=".*/" --exclude="*.snk" +rsync -r /home/marek/svn/dlr/svn/DLR_Main/Runtime/Microsoft.Scripting.Core/ Runtime/Microsoft.Scripting.Core --exclude=".*/" --exclude="*.snk" |