Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions azure-pipelines-official.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,11 @@ stages:
displayName: Build and Test

jobs:
- ${{ if eq(variables['Build.SourceBranch'], 'refs/heads/release/dev17.0-vs-deps') }}:
- ${{ if eq(variables['Build.SourceBranch'], 'refs/heads/release/dev17.1-vs-deps') }}:
- template: /eng/common/templates/job/onelocbuild.yml
parameters:
MirrorRepo: roslyn
MirrorBranch: release/dev17.0-vs-deps
MirrorBranch: release/dev17.1-vs-deps
LclSource: lclFilesfromPackage
LclPackageId: 'LCL-JUNO-PROD-ROSLYN'

Expand Down
8 changes: 4 additions & 4 deletions eng/Version.Details.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,18 @@
</Dependency>
</ProductDependencies>
<ToolsetDependencies>
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="7.0.0-beta.21603.6">
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="7.0.0-beta.21610.4">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>b3e949192067c8acdaaae35015534f76e92d79d4</Sha>
<Sha>18adc5b47acce8bb03948baf578fca442d1029d4</Sha>
<SourceBuild RepoName="arcade" ManagedOnly="true" />
</Dependency>
<Dependency Name="Microsoft.Net.Compilers.Toolset" Version="4.1.0-2.21574.9">
<Uri>https://github.com/dotnet/roslyn</Uri>
<Sha>16333a806a64c3546faf0320063b66ff32936eaa</Sha>
</Dependency>
<Dependency Name="Microsoft.DotNet.Helix.Sdk" Version="7.0.0-beta.21603.6">
<Dependency Name="Microsoft.DotNet.Helix.Sdk" Version="7.0.0-beta.21610.4">
<Uri>https://github.com/dotnet/arcade</Uri>
<Sha>b3e949192067c8acdaaae35015534f76e92d79d4</Sha>
<Sha>18adc5b47acce8bb03948baf578fca442d1029d4</Sha>
</Dependency>
</ToolsetDependencies>
</Dependencies>
2 changes: 2 additions & 0 deletions eng/common/cross/armv6/sources.list.buster
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
deb http://raspbian.raspberrypi.org/raspbian/ buster main contrib non-free rpi
deb-src http://raspbian.raspberrypi.org/raspbian/ buster main contrib non-free rpi
17 changes: 16 additions & 1 deletion eng/common/cross/build-rootfs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,15 @@ while :; do
__AlpineArch=armv7
__QEMUArch=arm
;;
armv6)
__BuildArch=armv6
__UbuntuArch=armhf
__QEMUArch=arm
__UbuntuRepo="http://raspbian.raspberrypi.org/raspbian/"
__CodeName=buster
__LLDB_Package="liblldb-6.0-dev"
__Keyring="/usr/share/keyrings/raspbian-archive-keyring.gpg"
;;
arm64)
__BuildArch=arm64
__UbuntuArch=arm64
Expand Down Expand Up @@ -236,6 +245,12 @@ while :; do
shift
done

if [ -e "$__Keyring" ]; then
__Keyring="--keyring=$__Keyring"
else
__Keyring=""
fi

if [ "$__BuildArch" == "armel" ]; then
__LLDB_Package="lldb-3.5-dev"
fi
Expand Down Expand Up @@ -337,7 +352,7 @@ elif [[ "$__CodeName" == "illumos" ]]; then
wget -P "$__RootfsDir"/usr/include/netpacket https://raw.githubusercontent.com/illumos/illumos-gate/master/usr/src/uts/common/inet/sockmods/netpacket/packet.h
wget -P "$__RootfsDir"/usr/include/sys https://raw.githubusercontent.com/illumos/illumos-gate/master/usr/src/uts/common/sys/sdt.h
elif [[ -n $__CodeName ]]; then
qemu-debootstrap --arch $__UbuntuArch $__CodeName $__RootfsDir $__UbuntuRepo
qemu-debootstrap $__Keyring --arch $__UbuntuArch $__CodeName $__RootfsDir $__UbuntuRepo
cp $__CrossDir/$__BuildArch/sources.list.$__CodeName $__RootfsDir/etc/apt/sources.list
chroot $__RootfsDir apt-get update
chroot $__RootfsDir apt-get -f -y install
Expand Down
69 changes: 9 additions & 60 deletions eng/common/templates/job/execute-sdl.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,14 +51,9 @@ jobs:
value: ${{ parameters.AzDOPipelineId }}
- name: AzDOBuildId
value: ${{ parameters.AzDOBuildId }}
# The Guardian version specified in 'eng/common/sdl/packages.config'. This value must be kept in
# sync with the packages.config file.
- name: DefaultGuardianVersion
value: 0.109.0
- template: /eng/common/templates/variables/sdl-variables.yml
- name: GuardianVersion
value: ${{ coalesce(parameters.overrideGuardianVersion, '$(DefaultGuardianVersion)') }}
- name: GuardianPackagesConfigFile
value: $(Build.SourcesDirectory)\eng\common\sdl\packages.config
pool:
vmImage: windows-2019
steps:
Expand Down Expand Up @@ -125,57 +120,11 @@ jobs:
displayName: Extract Archive Artifacts
continueOnError: ${{ parameters.sdlContinueOnError }}

- ${{ if ne(parameters.overrideGuardianVersion, '') }}:
- powershell: |
$content = Get-Content $(GuardianPackagesConfigFile)

Write-Host "packages.config content was:`n$content"

$content = $content.Replace('$(DefaultGuardianVersion)', '$(GuardianVersion)')
$content | Set-Content $(GuardianPackagesConfigFile)

Write-Host "packages.config content updated to:`n$content"
displayName: Use overridden Guardian version ${{ parameters.overrideGuardianVersion }}

- task: NuGetToolInstaller@1
displayName: 'Install NuGet.exe'
- task: NuGetCommand@2
displayName: 'Install Guardian'
inputs:
restoreSolution: $(Build.SourcesDirectory)\eng\common\sdl\packages.config
feedsToUse: config
nugetConfigPath: $(Build.SourcesDirectory)\eng\common\sdl\NuGet.config
externalFeedCredentials: GuardianConnect
restoreDirectory: $(Build.SourcesDirectory)\.packages

- ${{ if ne(parameters.overrideParameters, '') }}:
- powershell: ${{ parameters.executeAllSdlToolsScript }} ${{ parameters.overrideParameters }}
displayName: Execute SDL
continueOnError: ${{ parameters.sdlContinueOnError }}
- ${{ if eq(parameters.overrideParameters, '') }}:
- powershell: ${{ parameters.executeAllSdlToolsScript }}
-GuardianPackageName Microsoft.Guardian.Cli.$(GuardianVersion)
-NugetPackageDirectory $(Build.SourcesDirectory)\.packages
-AzureDevOpsAccessToken $(dn-bot-dotnet-build-rw-code-rw)
${{ parameters.additionalParameters }}
displayName: Execute SDL
continueOnError: ${{ parameters.sdlContinueOnError }}

- ${{ if ne(parameters.publishGuardianDirectoryToPipeline, 'false') }}:
# We want to publish the Guardian results and configuration for easy diagnosis. However, the
# '.gdn' dir is a mix of configuration, results, extracted dependencies, and Guardian default
# tooling files. Some of these files are large and aren't useful during an investigation, so
# exclude them by simply deleting them before publishing. (As of writing, there is no documented
# way to selectively exclude a dir from the pipeline artifact publish task.)
- task: DeleteFiles@1
displayName: Delete Guardian dependencies to avoid uploading
inputs:
SourceFolder: $(Agent.BuildDirectory)/.gdn
Contents: |
c
i
condition: succeededOrFailed()
- publish: $(Agent.BuildDirectory)/.gdn
artifact: GuardianConfiguration
displayName: Publish GuardianConfiguration
condition: succeededOrFailed()
- template: /eng/common/templates/steps/execute-sdl.yml
parameters:
overrideGuardianVersion: ${{ parameters.overrideGuardianVersion }}
executeAllSdlToolsScript: ${{ parameters.executeAllSdlToolsScript }}
overrideParameters: ${{ parameters.overrideParameters }}
additionalParameters: ${{ parameters.additionalParameters }}
publishGuardianDirectoryToPipeline: ${{ parameters.publishGuardianDirectoryToPipeline }}
sdlContinueOnError: ${{ parameters.sdlContinueOnError }}
68 changes: 68 additions & 0 deletions eng/common/templates/steps/execute-sdl.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
parameters:
overrideGuardianVersion: ''
executeAllSdlToolsScript: ''
overrideParameters: ''
additionalParameters: ''
publishGuardianDirectoryToPipeline: false
sdlContinueOnError: false
condition: ''

steps:
- ${{ if ne(parameters.overrideGuardianVersion, '') }}:
- powershell: |
$content = Get-Content $(GuardianPackagesConfigFile)

Write-Host "packages.config content was:`n$content"

$content = $content.Replace('$(DefaultGuardianVersion)', '$(GuardianVersion)')
$content | Set-Content $(GuardianPackagesConfigFile)

Write-Host "packages.config content updated to:`n$content"
displayName: Use overridden Guardian version ${{ parameters.overrideGuardianVersion }}

- task: NuGetToolInstaller@1
displayName: 'Install NuGet.exe'

- task: NuGetCommand@2
displayName: 'Install Guardian'
inputs:
restoreSolution: $(Build.SourcesDirectory)\eng\common\sdl\packages.config
feedsToUse: config
nugetConfigPath: $(Build.SourcesDirectory)\eng\common\sdl\NuGet.config
externalFeedCredentials: GuardianConnect
restoreDirectory: $(Build.SourcesDirectory)\.packages

- ${{ if ne(parameters.overrideParameters, '') }}:
- powershell: ${{ parameters.executeAllSdlToolsScript }} ${{ parameters.overrideParameters }}
displayName: Execute SDL
continueOnError: ${{ parameters.sdlContinueOnError }}
condition: ${{ parameters.condition }}

- ${{ if eq(parameters.overrideParameters, '') }}:
- powershell: ${{ parameters.executeAllSdlToolsScript }}
-GuardianPackageName Microsoft.Guardian.Cli.$(GuardianVersion)
-NugetPackageDirectory $(Build.SourcesDirectory)\.packages
-AzureDevOpsAccessToken $(dn-bot-dotnet-build-rw-code-rw)
${{ parameters.additionalParameters }}
displayName: Execute SDL
continueOnError: ${{ parameters.sdlContinueOnError }}
condition: ${{ parameters.condition }}

- ${{ if ne(parameters.publishGuardianDirectoryToPipeline, 'false') }}:
# We want to publish the Guardian results and configuration for easy diagnosis. However, the
# '.gdn' dir is a mix of configuration, results, extracted dependencies, and Guardian default
# tooling files. Some of these files are large and aren't useful during an investigation, so
# exclude them by simply deleting them before publishing. (As of writing, there is no documented
# way to selectively exclude a dir from the pipeline artifact publish task.)
- task: DeleteFiles@1
displayName: Delete Guardian dependencies to avoid uploading
inputs:
SourceFolder: $(Agent.BuildDirectory)/.gdn
Contents: |
c
i
condition: succeededOrFailed()
- publish: $(Agent.BuildDirectory)/.gdn
artifact: GuardianConfiguration
displayName: Publish GuardianConfiguration
condition: succeededOrFailed()
7 changes: 7 additions & 0 deletions eng/common/templates/variables/sdl-variables.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
variables:
# The Guardian version specified in 'eng/common/sdl/packages.config'. This value must be kept in
# sync with the packages.config file.
- name: DefaultGuardianVersion
value: 0.109.0
- name: GuardianPackagesConfigFile
value: $(Build.SourcesDirectory)\eng\common\sdl\packages.config
4 changes: 2 additions & 2 deletions global.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"xcopy-msbuild": "16.10.0-preview2"
},
"msbuild-sdks": {
"Microsoft.DotNet.Arcade.Sdk": "7.0.0-beta.21603.6",
"Microsoft.DotNet.Helix.Sdk": "7.0.0-beta.21603.6"
"Microsoft.DotNet.Arcade.Sdk": "7.0.0-beta.21610.4",
"Microsoft.DotNet.Helix.Sdk": "7.0.0-beta.21610.4"
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -1488,7 +1488,7 @@ class Derived : Base
void Goo() { }

public override int Prop => throw new System.NotImplementedException();
}", options: Option(ImplementTypeOptions.Metadata.InsertionBehavior, ImplementTypeInsertionBehavior.AtTheEnd));
}", options: Option(ImplementTypeOptions.InsertionBehavior, ImplementTypeInsertionBehavior.AtTheEnd));
}

[WorkItem(17274, "https://github.com/dotnet/roslyn/issues/17274")]
Expand Down Expand Up @@ -1665,7 +1665,7 @@ class C : AbstractClass
public override int ReadWriteProp { get; set; }
public override int WriteOnlyProp { set => throw new System.NotImplementedException(); }
}", parameters: new TestParameters(options: Option(
ImplementTypeOptions.Metadata.PropertyGenerationBehavior,
ImplementTypeOptions.PropertyGenerationBehavior,
ImplementTypePropertyGenerationBehavior.PreferAutoProperties)));
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7287,7 +7287,7 @@ void M() { }
}",
Options =
{
{ ImplementTypeOptions.Metadata.InsertionBehavior, ImplementTypeInsertionBehavior.AtTheEnd },
{ ImplementTypeOptions.InsertionBehavior, ImplementTypeInsertionBehavior.AtTheEnd },
},
}.RunAsync();
}
Expand Down Expand Up @@ -7462,7 +7462,7 @@ class Class : IInterface
}",
Options =
{
{ ImplementTypeOptions.Metadata.PropertyGenerationBehavior, ImplementTypePropertyGenerationBehavior.PreferAutoProperties },
{ ImplementTypeOptions.PropertyGenerationBehavior, ImplementTypePropertyGenerationBehavior.PreferAutoProperties },
},
}.RunAsync();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ public class InvalidIdentifierStructureTests : AbstractSyntaxStructureProviderTe
internal override async Task<ImmutableArray<BlockSpan>> GetBlockSpansWorkerAsync(Document document, int position)
{
var outliningService = document.GetLanguageService<BlockStructureService>();
var options = BlockStructureOptions.From(document.Project);
return (await outliningService.GetBlockStructureAsync(document, options, CancellationToken.None)).Spans;

return (await outliningService.GetBlockStructureAsync(document, CancellationToken.None)).Spans;
}

[WorkItem(1174405, "http://vstfdevdiv:8080/DevDiv2/DevDiv/_workitems/edit/1174405")]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,9 +143,8 @@ protected sealed override async Task ProduceTagsAsync(
if (outliningService == null)
return;

var options = BlockStructureOptions.From(document.Project);
var blockStructure = await outliningService.GetBlockStructureAsync(
documentSnapshotSpan.Document, options, cancellationToken).ConfigureAwait(false);
documentSnapshotSpan.Document, cancellationToken).ConfigureAwait(false);

ProcessSpans(
context, documentSnapshotSpan.SnapshotSpan, outliningService,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,8 @@ private static async Task<ImmutableArray<BlockSpan>> GetSpansFromWorkspaceAsync(
var hostDocument = workspace.Documents.First();
var document = workspace.CurrentSolution.GetDocument(hostDocument.Id);
var outliningService = document.GetLanguageService<BlockStructureService>();
var options = BlockStructureOptions.From(document.Project);

var structure = await outliningService.GetBlockStructureAsync(document, options, CancellationToken.None);
var structure = await outliningService.GetBlockStructureAsync(document, CancellationToken.None);
return structure.Spans;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ Imports System.Diagnostics.CodeAnalysis
Imports System.Threading
Imports Microsoft.CodeAnalysis.Editor.VisualBasic.Utilities.CommandHandlers
Imports Microsoft.CodeAnalysis.ImplementAbstractClass
Imports Microsoft.CodeAnalysis.ImplementType
Imports Microsoft.CodeAnalysis.Options
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Imports Microsoft.VisualStudio.Commanding
Expand All @@ -33,22 +32,21 @@ Namespace Microsoft.CodeAnalysis.Editor.VisualBasic.ImplementAbstractClass

Protected Overrides Function TryGetNewDocument(
document As Document,
options As ImplementTypeOptions,
TypeSyntax As TypeSyntax,
typeSyntax As TypeSyntax,
cancellationToken As CancellationToken
) As Document

If TypeSyntax.Parent.Kind <> SyntaxKind.InheritsStatement Then
If typeSyntax.Parent.Kind <> SyntaxKind.InheritsStatement Then
Return Nothing
End If

Dim classBlock = TryCast(TypeSyntax.Parent.Parent, ClassBlockSyntax)
Dim classBlock = TryCast(typeSyntax.Parent.Parent, ClassBlockSyntax)
If classBlock Is Nothing Then
Return Nothing
End If

Dim updatedDocument = ImplementAbstractClassData.TryImplementAbstractClassAsync(
document, classBlock, classBlock.ClassStatement.Identifier, options, cancellationToken).WaitAndGetResult(cancellationToken)
document, classBlock, classBlock.ClassStatement.Identifier, cancellationToken).WaitAndGetResult(cancellationToken)
If updatedDocument IsNot Nothing AndAlso
updatedDocument.GetTextChangesAsync(document, cancellationToken).WaitAndGetResult(cancellationToken).Count = 0 Then
Return Nothing
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ Imports System.Diagnostics.CodeAnalysis
Imports System.Threading
Imports Microsoft.CodeAnalysis.Editor.VisualBasic.Utilities.CommandHandlers
Imports Microsoft.CodeAnalysis.ImplementInterface
Imports Microsoft.CodeAnalysis.ImplementType
Imports Microsoft.CodeAnalysis.Options
Imports Microsoft.CodeAnalysis.VisualBasic.Syntax
Imports Microsoft.VisualStudio.Commanding
Expand All @@ -33,7 +32,6 @@ Namespace Microsoft.CodeAnalysis.Editor.VisualBasic.ImplementInterface

Protected Overrides Function TryGetNewDocument(
document As Document,
options As ImplementTypeOptions,
typeSyntax As TypeSyntax,
cancellationToken As CancellationToken
) As Document
Expand All @@ -45,7 +43,6 @@ Namespace Microsoft.CodeAnalysis.Editor.VisualBasic.ImplementInterface
Dim service = document.GetLanguageService(Of IImplementInterfaceService)()
Dim updatedDocument = service.ImplementInterfaceAsync(
document,
options,
typeSyntax.Parent,
cancellationToken).WaitAndGetResult(cancellationToken)
If updatedDocument.GetTextChangesAsync(document, cancellationToken).WaitAndGetResult(cancellationToken).Count = 0 Then
Expand Down
Loading