Skip to content

Commit

Permalink
Merge pull request #59201 from ryzngard/features/rename_ui_rework
Browse files Browse the repository at this point in the history
Features/rename_UI_rework Merge Main
  • Loading branch information
msftbot[bot] authored Feb 2, 2022
2 parents 6166298 + 12ca3fc commit bac6292
Show file tree
Hide file tree
Showing 1,275 changed files with 50,008 additions and 20,915 deletions.
3 changes: 2 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"files.associations": {
"**/eng/pipelines/*.yml": "azure-pipelines"
}
},
"omnisharp.defaultLaunchSolution": "Compilers.sln",
}
7 changes: 0 additions & 7 deletions Roslyn.sln
Original file line number Diff line number Diff line change
Expand Up @@ -372,8 +372,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.CodeAnalysis.Comp
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Installer.Package", "src\Setup\Installer\Installer.Package.csproj", "{6A68FDF9-24B3-4CB6-A808-96BF50D1BCE5}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.CodeAnalysis.Workspaces.Desktop.UnitTests", "src\Workspaces\DesktopTest\Microsoft.CodeAnalysis.Workspaces.Desktop.UnitTests.csproj", "{23405307-7EFF-4774-8B11-8F5885439761}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Insertion", "Insertion", "{AFA5F921-0650-45E8-B293-51A0BB89DEA0}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DevDivInsertionFiles", "src\Setup\DevDivInsertionFiles\DevDivInsertionFiles.csproj", "{6362616E-6A47-48F0-9EE0-27800B306ACB}"
Expand Down Expand Up @@ -1148,10 +1146,6 @@ Global
{6A68FDF9-24B3-4CB6-A808-96BF50D1BCE5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{6A68FDF9-24B3-4CB6-A808-96BF50D1BCE5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{6A68FDF9-24B3-4CB6-A808-96BF50D1BCE5}.Release|Any CPU.Build.0 = Release|Any CPU
{23405307-7EFF-4774-8B11-8F5885439761}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{23405307-7EFF-4774-8B11-8F5885439761}.Debug|Any CPU.Build.0 = Debug|Any CPU
{23405307-7EFF-4774-8B11-8F5885439761}.Release|Any CPU.ActiveCfg = Release|Any CPU
{23405307-7EFF-4774-8B11-8F5885439761}.Release|Any CPU.Build.0 = Release|Any CPU
{6362616E-6A47-48F0-9EE0-27800B306ACB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{6362616E-6A47-48F0-9EE0-27800B306ACB}.Debug|Any CPU.Build.0 = Debug|Any CPU
{6362616E-6A47-48F0-9EE0-27800B306ACB}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand Down Expand Up @@ -1479,7 +1473,6 @@ Global
{B9843F65-262E-4F40-A0BC-2CBEF7563A44} = {C52D8057-43AF-40E6-A01B-6CDBB7301985}
{03607817-6800-40B6-BEAA-D6F437CD62B7} = {BE25E872-1667-4649-9D19-96B83E75A44E}
{6A68FDF9-24B3-4CB6-A808-96BF50D1BCE5} = {BE25E872-1667-4649-9D19-96B83E75A44E}
{23405307-7EFF-4774-8B11-8F5885439761} = {55A62CFA-1155-46F1-ADF3-BEEE51B58AB5}
{AFA5F921-0650-45E8-B293-51A0BB89DEA0} = {8DBA5174-B0AA-4561-82B1-A46607697753}
{6362616E-6A47-48F0-9EE0-27800B306ACB} = {AFA5F921-0650-45E8-B293-51A0BB89DEA0}
{8977A560-45C2-4EC2-A849-97335B382C74} = {FD0FAF5F-1DED-485C-99FA-84B97F3A8EEC}
Expand Down
51 changes: 32 additions & 19 deletions azure-pipelines-integration-corehost.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,33 +12,46 @@ trigger:
# Automatic building of all PRs is disabled in the pipeline's trigger page.
# See https://docs.microsoft.com/en-us/azure/devops/pipelines/repos/github?view=azure-devops&tabs=yaml#comment-triggers
pr:
- main
- main-vs-deps
- release/*
- features/*
- demos/*

variables:
- name: XUNIT_LOGS
value: $(Build.SourcesDirectory)\artifacts\log\$(_configuration)
branches:
include:
- main
- main-vs-deps
- release/*
- features/*
- demos/*
paths:
exclude:
- docs/*
- .github/*

jobs:
- job: VS_Integration_CoreHost
- job: VS_Integration_CoreHost_Debug
pool:
name: NetCore1ESPool-Public
demands: ImageOverride -equals $(queueName)
strategy:
maxParallel: 2
matrix:
debug:
_configuration: Debug
release:
_configuration: Release
timeoutInMinutes: 135

variables:
- name: XUNIT_LOGS
value: $(Build.SourcesDirectory)\artifacts\log\Debug
steps:
- template: eng/pipelines/test-integration-job.yml
parameters:
configuration: $(_configuration)
configuration: Debug
oop64bit: true
oopCoreClr: true

- ${{ if ne(variables['Build.Reason'], 'PullRequest') }}:
- job: VS_Integration_CoreHost_Release
pool:
name: NetCore1ESPool-Public
demands: ImageOverride -equals $(queueName)
timeoutInMinutes: 135
variables:
- name: XUNIT_LOGS
value: $(Build.SourcesDirectory)\artifacts\log\Debug
steps:
- template: eng/pipelines/test-integration-job.yml
parameters:
configuration: Release
oop64bit: true
oopCoreClr: true
9 changes: 9 additions & 0 deletions azure-pipelines-integration-dartlab.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# Roslyn integration test pipeline for validating against branch builds of VS.

trigger: none # Manual trigger for now
pr: none # Manual trigger for now

resources:
pipelines:
Expand All @@ -15,6 +16,13 @@ resources:
type: git
name: DartLab.Templates
ref: refs/heads/dev/bradwhit/RemoveCheckoutNone
- repository: RoslynMirror
endpoint: dnceng/internal dotnet-roslyn
type: git
name: internal/dotnet-roslyn
ref: $(Build.SourceBranchName)
trigger:
- main

variables:
- name: XUNIT_LOGS
Expand Down Expand Up @@ -54,6 +62,7 @@ stages:
filePath: $(DartLab.Path)\Scripts\VisualStudio\Build\Get-VisualStudioDropName.ps1
arguments: -DropNamePrefix 'Products' -VstsDropUrlsJson '$(Pipeline.Workspace)\VisualStudioBuildUnderTest\BuildArtifacts\VstsDropUrls.json' -OutVariableName 'VisualStudio.BuildUnderTest.ProductsDropName'
deployAndRunTestsStepList:
- checkout: RoslynMirror
- template: eng/pipelines/test-integration-job.yml
parameters:
configuration: $(_configuration)
Expand Down
90 changes: 63 additions & 27 deletions azure-pipelines-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,41 +8,77 @@ trigger:

# Branches that trigger builds on PR
pr:
- main
- main-vs-deps
- release/*
- features/*
- demos/*

variables:
- name: XUNIT_LOGS
value: $(Build.SourcesDirectory)\artifacts\log\$(_configuration)
branches:
include:
- main
- main-vs-deps
- release/*
- features/*
- demos/*
paths:
exclude:
- docs/*
- .github/*

jobs:
- job: VS_Integration
- ${{ if ne(variables['Build.Reason'], 'PullRequest') }}:
- job: VS_Integration_Debug_32
pool:
name: $(poolName)
demands: ImageOverride -equals $(queueName)
timeoutInMinutes: 135
variables:
- name: XUNIT_LOGS
value: $(Build.SourcesDirectory)\artifacts\log\Debug
steps:
- template: eng/pipelines/test-integration-job.yml
parameters:
configuration: Debug
oop64bit: false
lspEditor: false

- job: VS_Integration_Debug_64
pool:
name: $(poolName)
demands: ImageOverride -equals $(queueName)
strategy:
maxParallel: 4
matrix:
debug_32:
_configuration: Debug
_oop64bit: false
debug_64:
_configuration: Debug
_oop64bit: true
release_32:
_configuration: Release
_oop64bit: false
release_64:
_configuration: Release
_oop64bit: true
timeoutInMinutes: 135
variables:
- name: XUNIT_LOGS
value: $(Build.SourcesDirectory)\artifacts\log\Debug
steps:
- template: eng/pipelines/test-integration-job.yml
parameters:
configuration: Debug
oop64bit: true
lspEditor: false

- job: VS_Integration_Release_32
pool:
name: $(poolName)
demands: ImageOverride -equals $(queueName)
timeoutInMinutes: 135
variables:
- name: XUNIT_LOGS
value: $(Build.SourcesDirectory)\artifacts\log\Release
steps:
- template: eng/pipelines/test-integration-job.yml
parameters:
configuration: $(_configuration)
oop64bit: $(_oop64bit)
configuration: Release
oop64bit: false
lspEditor: false

- ${{ if ne(variables['Build.Reason'], 'PullRequest') }}:
- job: VS_Integration_Release_64
pool:
name: $(poolName)
demands: ImageOverride -equals $(queueName)
timeoutInMinutes: 135
variables:
- name: XUNIT_LOGS
value: $(Build.SourcesDirectory)\artifacts\log\Release
steps:
- template: eng/pipelines/test-integration-job.yml
parameters:
configuration: Release
oop64bit: true
lspEditor: false
8 changes: 4 additions & 4 deletions azure-pipelines-official.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,9 @@ stages:

- stage: build
displayName: Build and Test
pool:
name: NetCore1ESPool-Svc-Internal
demands: ImageOverride -equals Build.Server.Amd64.VS2019

jobs:
- ${{ if eq(variables['Build.SourceBranch'], 'refs/heads/release/dev17.1-vs-deps') }}:
Expand All @@ -81,9 +84,6 @@ stages:
- job: OfficialBuild
displayName: Official Build
timeoutInMinutes: 360
pool:
name: NetCore1ESPool-Internal
demands: ImageOverride -equals Build.Server.Amd64.VS2019

steps:
- powershell: Write-Host "##vso[task.setvariable variable=SourceBranchName]$('$(Build.SourceBranch)'.Substring('refs/heads/'.Length))"
Expand Down Expand Up @@ -296,7 +296,7 @@ stages:
dependsOn:
- OfficialBuild
pool:
vmImage: vs2017-win2016
vmImage: windows-2019

- stage: insert
dependsOn:
Expand Down
18 changes: 12 additions & 6 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,17 @@ trigger:

# Branches that trigger builds on PR
pr:
- main
- main-vs-deps
- release/*
- features/*
- demos/*
branches:
include:
- main
- main-vs-deps
- release/*
- features/*
- demos/*
paths:
exclude:
- docs/*
- .github/*

# Windows Build and Test Jobs
jobs:
Expand Down Expand Up @@ -149,7 +155,7 @@ jobs:
buildJobName: Build_Unix_Debug
testArtifactName: Transport_Artifacts_Unix_Debug
configuration: Debug
testArguments: --testCoreClr --helixQueueName OSX.1014.Amd64.Open
testArguments: --testCoreClr --helixQueueName OSX.1015.Amd64.Open

- template: eng/common/templates/jobs/source-build.yml

Expand Down
17 changes: 10 additions & 7 deletions docs/Language Feature Status.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,18 +12,21 @@ efforts behind them.
| ------- | ------ | ----- | --------- | -------- | --------- |
| [Newlines in interpolations](https://github.com/dotnet/csharplang/issues/4935) | main | [Merged in 17.1p1](https://github.com/dotnet/roslyn/issues/57154) | [CyrusNajmabadi](https://github.com/CyrusNajmabadi) | [jcouv](https://github.com/jcouv), [chsienki](https://github.com/chsienki) | [CyrusNajmabadi](https://github.com/CyrusNajmabadi) |
| [List patterns](https://github.com/dotnet/csharplang/issues/3435) | [list-patterns](https://github.com/dotnet/roslyn/tree/features/list-patterns) | [Merged in 17.1p2](https://github.com/dotnet/roslyn/issues/51289) | [alrz](https://github.com/alrz) | [jcouv](https://github.com/jcouv), [333fred](https://github.com/333fred) | [333fred](https://github.com/333fred) |
| [Parameter null-checking](https://github.com/dotnet/csharplang/issues/2145) | [param-nullchecking](https://github.com/dotnet/roslyn/tree/features/param-nullchecking) | [In Progress](https://github.com/dotnet/roslyn/issues/36024) | [RikkiGibson](https://github.com/RikkiGibson), [fayrose](https://github.com/fayrose) | [cston](https://github.com/cston), [chsienki](https://github.com/chsienki) | [jaredpar](https://github.com/jaredpar) |
| [Raw string literals](https://github.com/dotnet/csharplang/issues/4304) | [RawStringLiterals](https://github.com/dotnet/roslyn/tree/features/features/RawStringLiterals) | [In Progress](https://github.com/dotnet/roslyn/issues/55306) | [CyrusNajmabadi](https://github.com/CyrusNajmabadi) | [jcouv](https://github.com/jcouv) | [CyrusNajmabadi](https://github.com/CyrusNajmabadi) |
| [Parameter null-checking](https://github.com/dotnet/csharplang/issues/2145) | [param-nullchecking](https://github.com/dotnet/roslyn/tree/features/param-nullchecking) | [Merged in 17.1p3](https://github.com/dotnet/roslyn/issues/36024) | [RikkiGibson](https://github.com/RikkiGibson), [fayrose](https://github.com/fayrose) | [cston](https://github.com/cston), [chsienki](https://github.com/chsienki) | [jaredpar](https://github.com/jaredpar) |
| [Raw string literals](https://github.com/dotnet/csharplang/issues/4304) | [RawStringLiterals](https://github.com/dotnet/roslyn/tree/features/RawStringLiterals) | [In Progress](https://github.com/dotnet/roslyn/issues/55306) | [CyrusNajmabadi](https://github.com/CyrusNajmabadi) | [jcouv](https://github.com/jcouv) | [CyrusNajmabadi](https://github.com/CyrusNajmabadi) |
| [nameof(parameter)](https://github.com/dotnet/csharplang/issues/373) | main | [In Progress](https://github.com/dotnet/roslyn/issues/40524) | [jcouv](https://github.com/jcouv) | TBD | [jcouv](https://github.com/jcouv) |
| [Relax ordering of `ref` and `partial` modifiers](https://github.com/dotnet/csharplang/issues/946) | [ref-partial](https://github.com/dotnet/roslyn/tree/features/ref-partial) | In Progress | [alrz](https://github.com/alrz) | [gafter](https://github.com/gafter) | [jcouv](https://github.com/jcouv) |
| [Generic attributes](https://github.com/dotnet/csharplang/issues/124) | [generic-attributes](https://github.com/dotnet/roslyn/tree/features/generic-attributes) | [Merged into 17.0p4 (preview langver)](https://github.com/dotnet/roslyn/issues/36285) | [AviAvni](https://github.com/AviAvni) | [RikkiGibson](https://github.com/RikkiGibson), [jcouv](https://github.com/jcouv) | [mattwar](https://github.com/mattwar) |
| [Default in deconstruction](https://github.com/dotnet/roslyn/pull/25562) | [decon-default](https://github.com/dotnet/roslyn/tree/features/decon-default) | [Implemented](https://github.com/dotnet/roslyn/issues/25559) | [jcouv](https://github.com/jcouv) | [gafter](https://github.com/gafter) | [jcouv](https://github.com/jcouv) |
| [Semi-auto-properties](https://github.com/dotnet/csharplang/issues/140) | [semi-auto-properties](https://github.com/dotnet/roslyn/tree/features/features/semi-auto-properties) | [In Progress](https://github.com/dotnet/roslyn/issues/57012) | [Youssef1313](https://github.com/Youssef1313) | TBD | [CyrusNajmabadi](https://github.com/CyrusNajmabadi) |
| [Semi-auto-properties](https://github.com/dotnet/csharplang/issues/140) | [semi-auto-props](https://github.com/dotnet/roslyn/tree/features/semi-auto-props) | [In Progress](https://github.com/dotnet/roslyn/issues/57012) | [Youssef1313](https://github.com/Youssef1313) | [333fred](https://github.com/333fred), [RikkiGibson](https://github.com/RikkiGibson) | [CyrusNajmabadi](https://github.com/CyrusNajmabadi) |
| [Required members](https://github.com/dotnet/csharplang/issues/3630) | [required-members](https://github.com/dotnet/roslyn/tree/features/required-members) | [In Progress](https://github.com/dotnet/roslyn/issues/57046) | [333fred](https://github.com/333fred) | [jcouv](https://github.com/jcouv), [RikkiGibson](https://github.com/RikkiGibson) | [333fred](https://github.com/333fred) |
| [Top Level statement attribute specifiers](https://github.com/dotnet/csharplang/issues/5045) | [main-attributes](https://github.com/dotnet/roslyn/tree/features/features/main-attributes) | [In Progress](https://github.com/dotnet/roslyn/issues/57047) | [chsienki](https://github.com/chsienki) | TBD | [jaredpar](https://github.com/jaredpar) |
| [Primary Constructors](https://github.com/dotnet/csharplang/issues/2691) | [primary-constructors](https://github.com/dotnet/roslyn/tree/features/features/primary-constructors) | [In Progress](https://github.com/dotnet/roslyn/issues/57048) | TBD | TBD | [MadsTorgersen](https://github.com/MadsTorgersen) |
| [Params Span<T> + Stackalloc any array type](https://github.com/dotnet/csharplang/issues/1757) | [params-span](https://github.com/dotnet/roslyn/tree/features/features/params-span) | [In Progress](https://github.com/dotnet/roslyn/issues/57049) | [cston](https://github.com/cston) | TBD | [jaredpar](https://github.com/jaredpar) |

| [Top Level statement attribute specifiers](https://github.com/dotnet/csharplang/issues/5045) | [main-attributes](https://github.com/dotnet/roslyn/tree/features/main-attributes) | [In Progress](https://github.com/dotnet/roslyn/issues/57047) | [chsienki](https://github.com/chsienki) | TBD | [jaredpar](https://github.com/jaredpar) |
| [Primary Constructors](https://github.com/dotnet/csharplang/issues/2691) | [primary-constructors](https://github.com/dotnet/roslyn/tree/features/primary-constructors) | [In Progress](https://github.com/dotnet/roslyn/issues/57048) | TBD | TBD | [MadsTorgersen](https://github.com/MadsTorgersen) |
| [Params Span\<T> + Stackalloc any array type](https://github.com/dotnet/csharplang/issues/1757) | [params-span](https://github.com/dotnet/roslyn/tree/features/params-span) | [In Progress](https://github.com/dotnet/roslyn/issues/57049) | [cston](https://github.com/cston) | TBD | [jaredpar](https://github.com/jaredpar) |
| [Cache delegates for static method group](https://github.com/dotnet/roslyn/issues/5835) | main | [In Progress](https://github.com/dotnet/roslyn/pull/58288) | [pawchen](https://github.com/pawchen) | [AlekseyTs](https://github.com/AlekseyTs), [jcouv](https://github.com/jcouv) | [AlekseyTs](https://github.com/AlekseyTs) |
| [Switch on ReadOnlySpan<char>](https://github.com/dotnet/csharplang/issues/1881) | main | [In Progress](https://github.com/dotnet/roslyn/pull/44388) | [YairHalberstadt ](https://github.com/YairHalberstadt) | [cston](https://github.com/cston), [RikkiGibson](https://github.com/RikkiGibson) | [jcouv](https://github.com/jcouv) |
| [nameof accessing instance memebers](https://github.com/dotnet/roslyn/issues/40229) | main | [In Progress](https://github.com/dotnet/roslyn/pull/48754) | [YairHalberstadt ](https://github.com/YairHalberstadt) | [333fred](https://github.com/333fred), [AlekseyTs](https://github.com/AlekseyTs) | [333fred](https://github.com/333fred) |
| [Utf8 String Literals](https://github.com/dotnet/csharplang/issues/184) | [Utf8StringLiterals](https://github.com/dotnet/roslyn/tree/features/Utf8StringLiterals) | [In Progress](https://github.com/dotnet/roslyn/issues/58848) | [AlekseyTs](https://github.com/AlekseyTs) | [cston](https://github.com/cston), [RikkiGibson](https://github.com/RikkiGibson) | [MadsTorgersen](https://github.com/MadsTorgersen) |

# C# 10.0

Expand Down
21 changes: 21 additions & 0 deletions docs/compilers/CSharp/Compiler Breaking Changes - DotNet 6.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,3 +108,24 @@ These are _function_type_conversions_.
}
}
```

4. In Visual Studio 17.1, `struct` type declarations with field initializers must include an explicitly declared constructor. Additionally, all fields must be definitely assigned in `struct` instance constructors that do not have a `: this()` initializer so any previously unassigned fields must be assigned from the added constructor or from field initializers.

For instance, the following results in an error in 17.1:
```csharp
struct S
{
int X = 1; // error: struct with field initializers must include an explicitly declared constructor
int Y;
}
```

The error could be resolved by adding a constructor and assigning the other field.
```csharp
struct S
{
int X = 1;
int Y;
public S() { Y = 0; } // ok
}
```
10 changes: 5 additions & 5 deletions docs/compilers/CSharp/Compiler Breaking Changes - DotNet 7.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,10 @@ Those types can be used with implicit Index indexer and list patterns.
5. Starting with Visual Studio 17.1, format specifiers in interpolated strings can not contain curly braces (either `{` or `}`). In previous versions `{{` was interpreted as an escaped `{` and `}}` was interpreted as an escaped `}` char in the format specifier. Now the first `}` char in a format specifier ends the interpolation, and any `{` char is an error.
https://github.com/dotnet/roslyn/issues/5775
```csharp
using System;
```csharp
using System;

Console.WriteLine($"{{{12:X}}}");
Console.WriteLine($"{{{12:X}}}");

//prints now: "{C}" - not "{X}}"
```
//prints now: "{C}" - not "{X}}"
```
Loading

0 comments on commit bac6292

Please sign in to comment.