Merge remote-tracking branch 'origin/release/2.2'

This commit is contained in:
Pranav K 2018-07-31 11:20:42 -07:00
Родитель 49822c79fa e094d2579e
Коммит 30165d2094
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 1963DA6D96C3057A
3 изменённых файлов: 6 добавлений и 2 удалений

Просмотреть файл

@ -6,8 +6,8 @@
<InternalAspNetCoreSdkPackageVersion>3.0.0-alpha1-10015</InternalAspNetCoreSdkPackageVersion>
<MicrosoftAspNetCoreAuthenticationCookiesPackageVersion>3.0.0-alpha1-10173</MicrosoftAspNetCoreAuthenticationCookiesPackageVersion>
<MicrosoftAspNetCoreHostingPackageVersion>3.0.0-alpha1-10173</MicrosoftAspNetCoreHostingPackageVersion>
<MicrosoftAspNetCoreMvcPackageVersion>3.0.0-alpha1-10173</MicrosoftAspNetCoreMvcPackageVersion>
<MicrosoftAspNetCoreMvcRazorPagesPackageVersion>3.0.0-alpha1-10173</MicrosoftAspNetCoreMvcRazorPagesPackageVersion>
<MicrosoftAspNetCoreMvcPackageVersion>2.2.0-a-preview1-obs-18917</MicrosoftAspNetCoreMvcPackageVersion>
<MicrosoftAspNetCoreMvcRazorPagesPackageVersion>2.2.0-a-preview1-obs-18917</MicrosoftAspNetCoreMvcRazorPagesPackageVersion>
<MicrosoftAspNetCoreRazorDesignPackageVersion>3.0.0-alpha1-10173</MicrosoftAspNetCoreRazorDesignPackageVersion>
<MicrosoftAspNetCoreRazorRuntimePackageVersion>3.0.0-alpha1-10173</MicrosoftAspNetCoreRazorRuntimePackageVersion>
<MicrosoftAspNetCoreServerIntegrationTestingPackageVersion>0.7.0-alpha1-10173</MicrosoftAspNetCoreServerIntegrationTestingPackageVersion>

Просмотреть файл

@ -179,7 +179,9 @@ namespace Microsoft.AspNetCore.Mvc.Razor.ViewCompilation.Internal
// Post process the compilation - run ExpressionRewritter and any user specified callbacks.
compilation = ExpressionRewriter.Rewrite(compilation);
var compilationContext = new RoslynCompilationContext(compilation);
#pragma warning disable CS0618 // Type or member is obsolete
MvcServiceProvider.ViewEngineOptions.CompilationCallback(compilationContext);
#pragma warning restore CS0618 // Type or member is obsolete
compilation = AssemblyMetadataGenerator.AddAssemblyMetadata(
compiler,
compilationContext.Compilation,

Просмотреть файл

@ -29,8 +29,10 @@ namespace ApplicationWithConfigureStartup
{
builder.AddRazorOptions(options =>
{
#pragma warning disable CS0618 // Type or member is obsolete
var callback = options.CompilationCallback;
options.CompilationCallback = context =>
#pragma warning restore CS0618 // Type or member is obsolete
{
callback(context);
foreach (var tree in context.Compilation.SyntaxTrees)