Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't emit #line default and #line hidden between consecutive using directives #9991

Merged
merged 11 commits into from
Mar 6, 2024
Merged
  •  
  •  
  •  
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#pragma warning disable 1591
namespace AspNetCore
{
#line hidden
#line default
using TModel = global::System.Object;
using System;
using System.Collections.Generic;
Expand All @@ -11,6 +11,8 @@ namespace AspNetCore
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.AspNetCore.Mvc.ViewFeatures;
#line default
#line hidden
public class TestFiles_IntegrationTests_CodeGenerationIntegrationTest_Basic : global::Microsoft.AspNetCore.Mvc.Razor.RazorPage<dynamic>
{
#pragma warning disable 219
Expand Down
Original file line number Diff line number Diff line change
@@ -1,34 +1,34 @@
Source Location: (13:0,13 [15] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/Basic.cshtml)
|this.ToString()|
Generated Location: (1023:26,13 [15] )
Generated Location: (1061:28,13 [15] )
|this.ToString()|

Source Location: (54:2,5 [29] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/Basic.cshtml)
|string.Format("{0}", "Hello")|
Generated Location: (1159:31,6 [29] )
Generated Location: (1197:33,6 [29] )
|string.Format("{0}", "Hello")|

Source Location: (95:4,2 [25] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/Basic.cshtml)
|
var cls = "foo";
|
Generated Location: (1305:36,2 [25] )
Generated Location: (1343:38,2 [25] )
|
var cls = "foo";
|

Source Location: (134:7,11 [18] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/Basic.cshtml)
|if(cls != null) { |
Generated Location: (1453:42,11 [18] )
Generated Location: (1491:44,11 [18] )
|if(cls != null) { |

Source Location: (153:7,30 [3] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/Basic.cshtml)
|cls|
Generated Location: (1615:47,30 [3] )
Generated Location: (1653:49,30 [3] )
|cls|

Source Location: (156:7,33 [2] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/Basic.cshtml)
| }|
Generated Location: (1766:52,33 [2] )
Generated Location: (1804:54,33 [2] )
| }|

Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#pragma warning disable 1591
namespace AspNetCore
{
#line hidden
#line default
using TModel = global::System.Object;
using System;
using System.Collections.Generic;
Expand All @@ -11,6 +11,8 @@ namespace AspNetCore
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.AspNetCore.Mvc.ViewFeatures;
#line default
#line hidden
public class TestFiles_IntegrationTests_CodeGenerationIntegrationTest_IncompleteDirectives : global::Microsoft.AspNetCore.Mvc.Razor.RazorPage<dynamic>
{
#pragma warning disable 219
Expand Down
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
Source Location: (102:3,7 [0] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/IncompleteDirectives.cshtml)
||
Generated Location: (784:19,0 [0] )
Generated Location: (822:21,0 [0] )
||

Source Location: (123:6,8 [0] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/IncompleteDirectives.cshtml)
||
Generated Location: (982:27,0 [0] )
Generated Location: (1020:29,0 [0] )
||

Source Location: (133:7,8 [17] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/IncompleteDirectives.cshtml)
|MyService<TModel>|
Generated Location: (1180:35,0 [17] )
Generated Location: (1218:37,0 [17] )
|MyService<TModel>|

Source Location: (93:2,6 [0] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/IncompleteDirectives.cshtml)
||
Generated Location: (1680:50,6 [0] )
Generated Location: (1718:52,6 [0] )
||

Source Location: (113:5,7 [0] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/IncompleteDirectives.cshtml)
||
Generated Location: (1816:55,7 [0] )
Generated Location: (1854:57,7 [0] )
||

Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#pragma warning disable 1591
namespace AspNetCore
{
#line hidden
#line default
using TModel = global::System.Object;
using System;
using System.Collections.Generic;
Expand All @@ -11,6 +11,8 @@ namespace AspNetCore
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.AspNetCore.Mvc.ViewFeatures;
#line default
#line hidden
public class TestFiles_IntegrationTests_CodeGenerationIntegrationTest_InheritsViewModel : MyBasePageForViews<MyModel>
{
#pragma warning disable 219
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
Source Location: (10:0,10 [26] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InheritsViewModel.cshtml)
|MyBasePageForViews<TModel>|
Generated Location: (748:19,0 [26] )
Generated Location: (786:21,0 [26] )
|MyBasePageForViews<TModel>|

Source Location: (45:1,7 [7] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InheritsViewModel.cshtml)
|MyModel|
Generated Location: (992:27,0 [7] )
Generated Location: (1030:29,0 [7] )
|MyModel|

Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#pragma warning disable 1591
namespace AspNetCore
{
#line hidden
#line default
using TModel = global::System.Object;
using System;
using System.Collections.Generic;
Expand All @@ -11,6 +11,8 @@ namespace AspNetCore
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.AspNetCore.Mvc.ViewFeatures;
#line default
#line hidden
public class TestFiles_IntegrationTests_CodeGenerationIntegrationTest_InheritsWithViewImports : MyBasePageForViews<MyModel>
{
#pragma warning disable 219
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Source Location: (7:0,7 [7] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InheritsWithViewImports.cshtml)
|MyModel|
Generated Location: (760:19,0 [7] )
Generated Location: (798:21,0 [7] )
|MyModel|

Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#pragma warning disable 1591
namespace AspNetCore
{
#line hidden
#line default
using TModel = global::System.Object;
using System;
using System.Collections.Generic;
Expand All @@ -11,6 +11,8 @@ namespace AspNetCore
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.AspNetCore.Mvc.ViewFeatures;
#line default
#line hidden
public class TestFiles_IntegrationTests_CodeGenerationIntegrationTest_InjectWithModel : global::Microsoft.AspNetCore.Mvc.Razor.RazorPage<MyModel>
{
#pragma warning disable 219
Expand Down
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
Source Location: (7:0,7 [7] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithModel.cshtml)
|MyModel|
Generated Location: (774:19,0 [7] )
Generated Location: (812:21,0 [7] )
|MyModel|

Source Location: (24:1,8 [5] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithModel.cshtml)
|MyApp|
Generated Location: (997:27,0 [5] )
Generated Location: (1035:29,0 [5] )
|MyApp|

Source Location: (30:1,14 [14] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithModel.cshtml)
|MyPropertyName|
Generated Location: (1240:35,22 [14] )
Generated Location: (1278:37,22 [14] )
|MyPropertyName|

Source Location: (54:2,8 [17] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithModel.cshtml)
|MyService<TModel>|
Generated Location: (1454:43,0 [17] )
Generated Location: (1492:45,0 [17] )
|MyService<TModel>|

Source Location: (72:2,26 [4] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithModel.cshtml)
|Html|
Generated Location: (1709:51,22 [4] )
Generated Location: (1747:53,22 [4] )
|Html|

Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#pragma warning disable 1591
namespace AspNetCore
{
#line hidden
#line default
using TModel = global::System.Object;
using System;
using System.Collections.Generic;
Expand All @@ -11,6 +11,8 @@ namespace AspNetCore
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.AspNetCore.Mvc.ViewFeatures;
#line default
#line hidden
public class TestFiles_IntegrationTests_CodeGenerationIntegrationTest_InjectWithSemicolon : global::Microsoft.AspNetCore.Mvc.Razor.RazorPage<MyModel>
{
#pragma warning disable 219
Expand Down
Original file line number Diff line number Diff line change
@@ -1,45 +1,45 @@
Source Location: (7:0,7 [7] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithSemicolon.cshtml)
|MyModel|
Generated Location: (782:19,0 [7] )
Generated Location: (820:21,0 [7] )
|MyModel|

Source Location: (24:1,8 [5] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithSemicolon.cshtml)
|MyApp|
Generated Location: (1009:27,0 [5] )
Generated Location: (1047:29,0 [5] )
|MyApp|

Source Location: (30:1,14 [14] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithSemicolon.cshtml)
|MyPropertyName|
Generated Location: (1256:35,22 [14] )
Generated Location: (1294:37,22 [14] )
|MyPropertyName|

Source Location: (58:2,8 [17] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithSemicolon.cshtml)
|MyService<TModel>|
Generated Location: (1474:43,0 [17] )
Generated Location: (1512:45,0 [17] )
|MyService<TModel>|

Source Location: (76:2,26 [4] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithSemicolon.cshtml)
|Html|
Generated Location: (1733:51,22 [4] )
Generated Location: (1771:53,22 [4] )
|Html|

Source Location: (93:3,8 [5] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithSemicolon.cshtml)
|MyApp|
Generated Location: (1941:59,0 [5] )
Generated Location: (1979:61,0 [5] )
|MyApp|

Source Location: (99:3,14 [15] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithSemicolon.cshtml)
|MyPropertyName2|
Generated Location: (2188:67,22 [15] )
Generated Location: (2226:69,22 [15] )
|MyPropertyName2|

Source Location: (129:4,8 [17] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithSemicolon.cshtml)
|MyService<TModel>|
Generated Location: (2407:75,0 [17] )
Generated Location: (2445:77,0 [17] )
|MyService<TModel>|

Source Location: (147:4,26 [5] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/InjectWithSemicolon.cshtml)
|Html2|
Generated Location: (2666:83,22 [5] )
Generated Location: (2704:85,22 [5] )
|Html2|

Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#pragma warning disable 1591
namespace AspNetCore
{
#line hidden
#line default
using TModel = global::System.Object;
using System;
using System.Collections.Generic;
Expand All @@ -11,6 +11,8 @@ namespace AspNetCore
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.AspNetCore.Mvc.ViewFeatures;
#line default
#line hidden
public class TestFiles_IntegrationTests_CodeGenerationIntegrationTest_Inject : global::Microsoft.AspNetCore.Mvc.Razor.RazorPage<dynamic>
{
#pragma warning disable 219
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
Source Location: (8:0,8 [5] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/Inject.cshtml)
|MyApp|
Generated Location: (756:19,0 [5] )
Generated Location: (794:21,0 [5] )
|MyApp|

Source Location: (14:0,14 [14] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/Inject.cshtml)
|MyPropertyName|
Generated Location: (990:27,22 [14] )
Generated Location: (1028:29,22 [14] )
|MyPropertyName|

Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#pragma warning disable 1591
namespace AspNetCore
{
#line hidden
#line default
using TModel = global::System.Object;
using System;
using System.Collections.Generic;
Expand All @@ -11,6 +11,8 @@ namespace AspNetCore
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.AspNetCore.Mvc.ViewFeatures;
#line default
#line hidden
public class TestFiles_IntegrationTests_CodeGenerationIntegrationTest_InvalidNamespaceAtEOF : global::Microsoft.AspNetCore.Mvc.Razor.RazorPage<dynamic>
{
#pragma warning disable 219
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#pragma warning disable 1591
namespace AspNetCore
{
#line hidden
#line default
using TModel = global::System.Object;
using System;
using System.Collections.Generic;
Expand All @@ -11,6 +11,8 @@ namespace AspNetCore
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.AspNetCore.Mvc.ViewFeatures;
#line default
#line hidden
public class TestFiles_IntegrationTests_CodeGenerationIntegrationTest_ModelExpressionTagHelper : global::Microsoft.AspNetCore.Mvc.Razor.RazorPage<DateTime>
{
#line hidden
Expand Down
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
Source Location: (7:0,7 [8] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/ModelExpressionTagHelper.cshtml)
|DateTime|
Generated Location: (1267:25,0 [8] )
Generated Location: (1305:27,0 [8] )
|DateTime|

Source Location: (33:2,14 [29] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/ModelExpressionTagHelper.cshtml)
|"InputTestTagHelper, AppCode"|
Generated Location: (1537:33,37 [29] )
Generated Location: (1575:35,37 [29] )
|"InputTestTagHelper, AppCode"|

Source Location: (83:4,17 [4] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/ModelExpressionTagHelper.cshtml)
|Date|
Generated Location: (2209:49,102 [4] )
Generated Location: (2247:51,102 [4] )
|Date|

Source Location: (111:5,18 [5] TestFiles/IntegrationTests/CodeGenerationIntegrationTest/ModelExpressionTagHelper.cshtml)
|Model|
Generated Location: (2601:56,94 [5] )
Generated Location: (2639:58,94 [5] )
|Model|

Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#pragma warning disable 1591
namespace AspNetCore
{
#line hidden
#line default
using TModel = global::System.Object;
using System;
using System.Collections.Generic;
Expand All @@ -11,6 +11,8 @@ namespace AspNetCore
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.AspNetCore.Mvc.ViewFeatures;
#line default
#line hidden
public class TestFiles_IntegrationTests_CodeGenerationIntegrationTest_Model : global::Microsoft.AspNetCore.Mvc.Razor.RazorPage<System.Collections.IEnumerable>
{
#pragma warning disable 219
Expand Down
Loading