Switching to use generations TFMs

This commit is contained in:
Pranav K 2015-10-21 18:11:20 -07:00
parent f0a4a9773d
commit ce39864623
18 changed files with 63 additions and 64 deletions

1
.gitignore vendored
View File

@ -25,3 +25,4 @@ nuget.exe
*.*sdf
*.ipch
project.lock.json
.vs

View File

@ -1,36 +1,37 @@
{
"description": "Supports tag helper resolution during precompilation.",
"version": "4.0.0-*",
"repository": {
"type": "git",
"url": "git://github.com/aspnet/razor"
"description": "Supports tag helper resolution during precompilation.",
"version": "4.0.0-*",
"repository": {
"type": "git",
"url": "git://github.com/aspnet/razor"
},
"compilationOptions": {
"warningsAsErrors": true
},
"dependencies": {
"Microsoft.Extensions.PropertyActivator.Sources": {
"version": "1.0.0-*",
"type": "build"
},
"compilationOptions": {
"warningsAsErrors": true
"Microsoft.Extensions.PropertyHelper.Sources": {
"version": "1.0.0-*",
"type": "build"
},
"dependencies": {
"Microsoft.Extensions.PropertyActivator.Sources": {
"version": "1.0.0-*",
"type": "build"
},
"Microsoft.Extensions.PropertyHelper.Sources": {
"version": "1.0.0-*",
"type": "build"
},
"Microsoft.AspNet.Razor.Runtime": "4.0.0-*",
"Microsoft.Dnx.Compilation.CSharp.Abstractions": "1.0.0-*"
"Microsoft.AspNet.Razor.Runtime": "4.0.0-*",
"Microsoft.Dnx.Compilation.CSharp.Abstractions": "1.0.0-*"
},
"frameworks": {
"net451": {
"frameworkAssemblies": {
"System.Runtime": "4.0.0.0"
}
},
"frameworks": {
"dnx451": {
"frameworkAssemblies": {
"System.Runtime": "4.0.0.0"
}
},
"dnxcore50": {
"dependencies": {
"System.Collections.Concurrent": "4.0.11-*",
"System.Linq.Expressions": "4.0.11-*"
}
}
"dotnet5.4": {
"dependencies": {
"System.Collections.Concurrent": "4.0.11-*",
"System.Linq.Expressions": "4.0.11-*",
"System.Reflection.TypeExtensions": "4.0.1-*"
}
}
}
}
}

View File

@ -204,7 +204,7 @@ namespace Microsoft.AspNet.Razor.Runtime.TagHelpers
public bool IsWhiteSpace { get; private set; } = true;
#if DNXCORE50
#if DOTNET5_4
// This is an abstract method in DNXCore
public override void Write(char value)
{

View File

@ -108,7 +108,7 @@ namespace Microsoft.AspNet.Razor.Runtime.TagHelpers
{
TagHelperDesignTimeDescriptor typeDesignTimeDescriptor = null;
#if !DNXCORE50
#if !DOTNET5_4
if (designTime)
{
var runtimeTypeInfo = typeInfo as RuntimeTypeInfo;
@ -702,7 +702,7 @@ namespace Microsoft.AspNet.Razor.Runtime.TagHelpers
{
TagHelperAttributeDesignTimeDescriptor propertyDesignTimeDescriptor = null;
#if !DNXCORE50
#if !DOTNET5_4
if (designTime)
{
var runtimeProperty = property as RuntimePropertyInfo;

View File

@ -1,7 +1,7 @@
// Copyright (c) .NET Foundation. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
#if !DNXCORE50 // Cannot accurately resolve the location of the documentation XML file in coreclr.
#if !DOTNET5_4 // Cannot accurately resolve the location of the documentation XML file in coreclr.
using System;
using System.Collections.Generic;
using System.Globalization;

View File

@ -1,7 +1,7 @@
// Copyright (c) .NET Foundation. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
#if !DNXCORE50
#if !DOTNET5_4
using System;
using System.Collections.Generic;
using System.Linq;

View File

@ -22,23 +22,17 @@
}
},
"frameworks": {
"net45": {
"net451": {
"frameworkAssemblies": {
"System.Xml": "4.0.0.0",
"System.Xml.Linq": "4.0.0.0"
}
},
"dnx451": {
"frameworkAssemblies": {
"System.Xml": "4.0.0.0",
"System.Xml.Linq": "4.0.0.0"
}
},
"dnxcore50": {
"dotnet5.4": {
"dependencies": {
"System.Reflection.Extensions": "4.0.1-beta-*",
"System.Text.RegularExpressions": "4.0.11-beta-*"
}
}
}
}
}

View File

@ -5,7 +5,11 @@
"xunit.assert": "2.1.0-*"
},
"frameworks": {
"net45": { },
"dotnet": { }
"net451": { },
"dotnet5.4": {
"dependencies": {
"System.Runtime": "4.0.21-beta-*"
}
}
}
}
}

View File

@ -4,7 +4,7 @@
using Microsoft.AspNet.Razor.Chunks.Generators;
using Microsoft.AspNet.Razor.CodeGenerators;
using Microsoft.AspNet.Razor.Parser;
#if NET45
#if NET451
#endif

View File

@ -310,7 +310,7 @@ namespace Microsoft.AspNet.Razor.Editor
RazorEditorTrace.TraceLine(RazorResources.FormatTrace_BackgroundThreadStart(fileNameOnly));
EnsureOnThread();
#if DNXCORE50
#if DOTNET5_4
var spinWait = new SpinWait();
#endif
@ -428,7 +428,7 @@ namespace Microsoft.AspNet.Razor.Editor
else
{
RazorEditorTrace.TraceLine(RazorResources.FormatTrace_NoChangesArrived(fileNameOnly));
#if DNXCORE50
#if DOTNET5_4
// This does the equivalent of thread.yield under the covers.
spinWait.SpinOnce();
#else

View File

@ -3,7 +3,7 @@
using System;
using System.Diagnostics;
#if NET45
#if NET451
using System.Globalization;
#endif
@ -20,7 +20,7 @@ namespace Microsoft.AspNet.Razor.Editor
bool enabled;
if (Boolean.TryParse(Environment.GetEnvironmentVariable("RAZOR_EDITOR_TRACE"), out enabled))
{
#if NET45
#if NET451
// No Trace in CoreCLR
Trace.WriteLine(RazorResources.FormatTrace_Startup(
@ -41,7 +41,7 @@ namespace Microsoft.AspNet.Razor.Editor
{
if (IsEnabled())
{
#if NET45
#if NET451
// No Trace in CoreCLR
Trace.WriteLine(RazorResources.FormatTrace_Format(

View File

@ -143,7 +143,7 @@ namespace Microsoft.AspNet.Razor.Parser
case CSharpSymbolType.GreaterThan:
return CSharpSymbolType.LessThan;
default:
#if NET45
#if NET451
// No Debug.Fail
Debug.Fail("FlipBracket must be called with a bracket character");
#else

View File

@ -88,7 +88,7 @@ namespace Microsoft.AspNet.Razor.Parser
case HtmlSymbolType.CloseAngle:
return HtmlSymbolType.OpenAngle;
default:
#if NET45
#if NET451
// No Debug.Fail in CoreCLR
Debug.Fail("FlipBracket must be called with a bracket character");

View File

@ -326,7 +326,7 @@ namespace Microsoft.AspNet.Razor.Parser
_infiniteLoopGuardCount++;
if (_infiniteLoopGuardCount > InfiniteLoopCountThreshold)
{
#if NET45
#if NET451
// No Debug.Fail in CoreCLR
Debug.Fail("An internal parser error is causing an infinite loop at this location.");

View File

@ -11,7 +11,7 @@ namespace Microsoft.AspNet.Razor
/// <summary>
/// A location in a Razor file.
/// </summary>
#if NET45
#if NET451
// No Serializable attribute in CoreCLR (no need for it anymore?)
[Serializable]
#endif

View File

@ -158,7 +158,7 @@ namespace Microsoft.AspNet.Razor.Tokenizer
TakeCurrent();
return EndSymbol(HtmlSymbolType.DoubleHyphen);
default:
#if NET45
#if NET451
// No Debug.Fail in CoreCLR
Debug.Fail("Unexpected symbol!");

View File

@ -281,7 +281,7 @@ namespace Microsoft.AspNet.Razor.Tokenizer
[Conditional("DEBUG")]
internal void AssertCurrent(char current)
{
#if NET45
#if NET451
// No Debug.Assert with this many arguments in CoreCLR
Debug.Assert(CurrentCharacter == current, "CurrentCharacter Assumption violated", "Assumed that the current character would be {0}, but it is actually {1}", current, CurrentCharacter);

View File

@ -12,9 +12,8 @@
}
},
"frameworks": {
"net45": { },
"dnx451": { },
"dnxcore50": {
"net451": {},
"dotnet5.4": {
"dependencies": {
"System.Diagnostics.Tools": "4.0.1-beta-*",
"System.IO.FileSystem": "4.0.1-beta-*",
@ -24,4 +23,4 @@
}
}
}
}
}