-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
On a brand new project with this csproj file, everything compiles fine:
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="TunnelVisionLabs.ReferenceAssemblyAnnotator" Version="1.0.0-alpha.160" PrivateAssets="all" />
<!-- Specifies the version of Microsoft.NETCore.App.Ref to obtain nullability information from. -->
<PackageDownload Include="Microsoft.NETCore.App.Ref" Version="[6.0.0]" />
</ItemGroup>
</Project>
However, if the csproj file is changed slightly, it no longer does:
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>netstandard2.0</TargetFrameworks>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="TunnelVisionLabs.ReferenceAssemblyAnnotator" Version="1.0.0-alpha.160" PrivateAssets="all" />
<!-- Specifies the version of Microsoft.NETCore.App.Ref to obtain nullability information from. -->
<PackageDownload Include="Microsoft.NETCore.App.Ref" Version="[6.0.0]" />
</ItemGroup>
</Project>
In Visual Studio 2022, I get this error:
MSB4184 The expression """.Substring(1)" cannot be evaluated. startIndex cannot be larger than length of string. Parameter name: startIndex
This points to a line in TunnelVisionLabs.ReferenceAssemblyAnnotator.targets:
<PropertyGroup Condition="'$(TargetFrameworkVersion.Substring(1))' >= '2.0'">
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels