Skip to content

Commit

Permalink
Merge pull request #3 from dotnet-campus/t/walterlv/fix
Browse files Browse the repository at this point in the history
修复几个严重的问题
  • Loading branch information
lindexi authored Jun 15, 2023
2 parents 45ebaba + 5d226dd commit 634bcba
Show file tree
Hide file tree
Showing 15 changed files with 16 additions and 46 deletions.
11 changes: 1 addition & 10 deletions dotnetCampus.LatestCSharpFeatures.sln
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "dotnetCampus.LatestCSharpFe
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "dotnetCampus.Nullable.Source", "src\dotnetCampus.Nullable.Source\dotnetCampus.Nullable.Source.csproj", "{72163C73-CBC5-4CB5-BDDF-769B7AFD6FAB}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "samples", "samples", "{19AD69CA-F593-4789-A51F-9E547033147D}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "InternalUsageLibrary", "samples\InternalUsageLibrary\InternalUsageLibrary.csproj", "{DF937968-A710-4079-86D2-B2483FF3D81F}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "dotnetCampus.LatestCSharpFeatures.Source", "src\dotnetCampus.LatestCSharpFeatures.Source\dotnetCampus.LatestCSharpFeatures.Source.csproj", "{16D75C29-3176-4CFD-A1B5-B5F24876B038}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "IsExternalInit", "IsExternalInit", "{4E06689B-E73A-4A04-AAA0-7959A6EC06E6}"
Expand All @@ -43,7 +39,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{CAB44C21-D58
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tests", "tests", "{878C1D77-0A77-44BD-847E-164188B10677}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "dotnetCampus.LatestCSharpFeatures.Tests", "tests\dotnetCampus.LatestCSharpFeatures.Tests\dotnetCampus.LatestCSharpFeatures.Tests.csproj", "{D10BF09A-FDF3-43F0-BD54-49A73554CDAB}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "dotnetCampus.LatestCSharpFeatures.Tests", "tests\dotnetCampus.LatestCSharpFeatures.Tests\dotnetCampus.LatestCSharpFeatures.Tests.csproj", "{D10BF09A-FDF3-43F0-BD54-49A73554CDAB}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "dotnetCampus.LatestCSharpFeatures.Analyzer", "src\dotnetCampus.LatestCSharpFeatures.Analyzer\dotnetCampus.LatestCSharpFeatures.Analyzer.csproj", "{642FA0CA-E827-4D96-9358-D596CD87DAF4}"
EndProject
Expand Down Expand Up @@ -81,10 +77,6 @@ Global
{72163C73-CBC5-4CB5-BDDF-769B7AFD6FAB}.Debug|Any CPU.Build.0 = Debug|Any CPU
{72163C73-CBC5-4CB5-BDDF-769B7AFD6FAB}.Release|Any CPU.ActiveCfg = Release|Any CPU
{72163C73-CBC5-4CB5-BDDF-769B7AFD6FAB}.Release|Any CPU.Build.0 = Release|Any CPU
{DF937968-A710-4079-86D2-B2483FF3D81F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{DF937968-A710-4079-86D2-B2483FF3D81F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{DF937968-A710-4079-86D2-B2483FF3D81F}.Release|Any CPU.ActiveCfg = Release|Any CPU
{DF937968-A710-4079-86D2-B2483FF3D81F}.Release|Any CPU.Build.0 = Release|Any CPU
{16D75C29-3176-4CFD-A1B5-B5F24876B038}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{16D75C29-3176-4CFD-A1B5-B5F24876B038}.Debug|Any CPU.Build.0 = Debug|Any CPU
{16D75C29-3176-4CFD-A1B5-B5F24876B038}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand All @@ -108,7 +100,6 @@ Global
{6ED76C7A-A16A-45A5-BC1F-91A880839C31} = {F0CBB519-BB38-4104-B840-4076BB206E36}
{4EBF62CB-613E-4496-B890-B1F433ED7581} = {F0CBB519-BB38-4104-B840-4076BB206E36}
{72163C73-CBC5-4CB5-BDDF-769B7AFD6FAB} = {CCAAE7A8-1879-4F67-98AA-D837C80227A2}
{DF937968-A710-4079-86D2-B2483FF3D81F} = {19AD69CA-F593-4789-A51F-9E547033147D}
{4E06689B-E73A-4A04-AAA0-7959A6EC06E6} = {CAB44C21-D58C-4732-B9D8-60B1DAE82BEF}
{CCAAE7A8-1879-4F67-98AA-D837C80227A2} = {CAB44C21-D58C-4732-B9D8-60B1DAE82BEF}
{F0CBB519-BB38-4104-B840-4076BB206E36} = {CAB44C21-D58C-4732-B9D8-60B1DAE82BEF}
Expand Down
8 changes: 0 additions & 8 deletions samples/InternalUsageLibrary/InternalUsageLibrary.csproj

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net5.0;netcoreapp3.0;netstandard1.0;net40</TargetFrameworks>
<TargetFrameworks>net5.0;netcoreapp3.0;netstandard2.0;net40</TargetFrameworks>
<RootNamespace>System.Diagnostics.CodeAnalysis</RootNamespace>
<PackageId>dotnetCampus.IsExternalInit</PackageId>
<Description>If you use C# 9.0 or later and want to use record types, this '.Source' library adds internal IsExternalInit attribute support to your project. This confines the new language feature to the project itself without affecting other projects that reference it.</Description>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net5.0;netcoreapp3.0;netstandard1.0;net40</TargetFrameworks>
<TargetFrameworks>net5.0;netcoreapp3.0;netstandard2.0;net40</TargetFrameworks>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<RootNamespace>System.Diagnostics.CodeAnalysis</RootNamespace>
<Description>If you use C# 9.0 or later and want to use record types, this library adds public IsExternalInit attribute support for your project, allowing the new language feature to be propagated to other projects that reference this one.</Description>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net5.0;netcoreapp3.0;netstandard1.0;net40</TargetFrameworks>
<TargetFrameworks>net5.0;netcoreapp3.0;netstandard2.0;net40</TargetFrameworks>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<RootNamespace>System.Diagnostics.CodeAnalysis</RootNamespace>
<Description>This comprehensive package provides support for the latest C# language features in your project, enabling older .NET projects to use newer C# language constructs. Currently includes support for 'nullable', 'init', and 'required' keywords. The types introduced are internal, confining these features to the project itself without affecting other projects that reference it. By installing this package, you get all the newest C# features in one place, eliminating the need to install separate packages for each feature. Future updates will include more new features as they are released.</Description>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net7.0;net5.0;netcoreapp3.0;netstandard1.0;net40</TargetFrameworks>
<TargetFrameworks>net7.0;net5.0;netcoreapp3.0;netstandard2.0;net40</TargetFrameworks>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<RootNamespace>System.Diagnostics.CodeAnalysis</RootNamespace>
<Description>This comprehensive package provides support for the latest C# language features in your project, enabling older .NET projects to use newer C# language constructs. Currently includes support for 'nullable', 'init', and 'required' keywords. The types introduced are public, allowing these features to propagate to other projects that reference this one. By installing this package, you get all the newest C# features in one place, eliminating the need to install separate packages for each feature. Future updates will include more new features as they are released.</Description>
Expand All @@ -12,9 +12,9 @@
</PropertyGroup>

<ItemGroup>
<Compile Include="..\dotnetCampus.Nullable\**\*.cs" Exclude="..\dotnetCampus.Nullable\**\obj\**\*.cs;..\dotnetCampus.Nullable\**\bin\**\*.cs" />
<Compile Include="..\dotnetCampus.IsExternalInit\**\*.cs" Exclude="..\dotnetCampus.IsExternalInit\**\obj\**\*.cs;..\dotnetCampus.IsExternalInit\**\bin\**\*.cs" />
<Compile Include="..\dotnetCampus.Required\**\*.cs" Exclude="..\dotnetCampus.Required\**\obj\**\*.cs;..\dotnetCampus.Required\**\bin\**\*.cs" />
<Compile Include="..\dotnetCampus.Nullable.Source\**\*.cs" Exclude="..\dotnetCampus.Nullable.Source\**\obj\**\*.cs;..\dotnetCampus.Nullable\**\bin\**\*.cs" />
<Compile Include="..\dotnetCampus.IsExternalInit.Source\**\*.cs" Exclude="..\dotnetCampus.IsExternalInit.Source\**\obj\**\*.cs;..\dotnetCampus.IsExternalInit\**\bin\**\*.cs" />
<Compile Include="..\dotnetCampus.Required.Source\**\*.cs" Exclude="..\dotnetCampus.Required.Source\**\obj\**\*.cs;..\dotnetCampus.Required\**\bin\**\*.cs" />
</ItemGroup>

<Target Name="IncludeAllDependencies" BeforeTargets="_GetPackageFiles">
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net5.0;netcoreapp3.0;netstandard1.0;net40</TargetFrameworks>
<TargetFrameworks>net5.0;netcoreapp3.0;netstandard2.0;net40</TargetFrameworks>
<RootNamespace>System.Diagnostics.CodeAnalysis</RootNamespace>
<PackageId>dotnetCampus.Nullable</PackageId>
<Description>If you use C# 8.0 or later and enable the nullable types, this '.Source' library adds internal nullable reference attributes to your project. This confines the new language feature to the project itself without affecting other projects that reference it.</Description>
Expand Down
2 changes: 1 addition & 1 deletion src/dotnetCampus.Nullable/dotnetCampus.Nullable.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net5.0;netcoreapp3.0;netstandard1.0;net40</TargetFrameworks>
<TargetFrameworks>net5.0;netcoreapp3.0;netstandard2.0;net40</TargetFrameworks>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<RootNamespace>System.Diagnostics.CodeAnalysis</RootNamespace>
<Description>If you use C# 8.0 or later and enable the nullable types, this library adds public nullable reference attributes to your project, allowing the new language feature to be propagated to other projects that reference this one.</Description>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net7.0;netcoreapp3.0;netstandard1.0;net40</TargetFrameworks>
<TargetFrameworks>net7.0;netcoreapp3.0;netstandard2.0;net40</TargetFrameworks>
<RootNamespace>System.Diagnostics.CodeAnalysis</RootNamespace>
<PackageId>dotnetCampus.Required</PackageId>
<Description>For C# 11.0 and newer. This package adds support for the 'required' keyword in your project, enforcing that fields or properties are initialized during object initialization. The types introduced are internal, meaning the 'required' functionality is limited to this project and won't propagate to referencing projects.</Description>
Expand Down
2 changes: 1 addition & 1 deletion src/dotnetCampus.Required/dotnetCampus.Required.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net7.0;net5.0;netcoreapp3.0;netstandard1.0;net40</TargetFrameworks>
<TargetFrameworks>net7.0;net5.0;netcoreapp3.0;netstandard2.0;net40</TargetFrameworks>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<RootNamespace>System.Diagnostics.CodeAnalysis</RootNamespace>
<Description>If you use C# 9.0 or later and want to use record types, this library adds public IsExternalInit attribute support for your project, allowing the new language feature to be propagated to other projects that reference this one.</Description>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,8 @@

namespace dotnetCampus.LatestCSharpFeatures.Tests;

[TestClass]
public class IsExternalInitTest

Check warning on line 5 in tests/dotnetCampus.LatestCSharpFeatures.Tests/IsExternalInitTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'IsExternalInitTest'

Check warning on line 5 in tests/dotnetCampus.LatestCSharpFeatures.Tests/IsExternalInitTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'IsExternalInitTest'

Check warning on line 5 in tests/dotnetCampus.LatestCSharpFeatures.Tests/IsExternalInitTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'IsExternalInitTest'

Check warning on line 5 in tests/dotnetCampus.LatestCSharpFeatures.Tests/IsExternalInitTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'IsExternalInitTest'

Check warning on line 5 in tests/dotnetCampus.LatestCSharpFeatures.Tests/IsExternalInitTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'IsExternalInitTest'
{
[TestMethod]
public void CanBeCompiled()

Check warning on line 7 in tests/dotnetCampus.LatestCSharpFeatures.Tests/IsExternalInitTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'IsExternalInitTest.CanBeCompiled()'

Check warning on line 7 in tests/dotnetCampus.LatestCSharpFeatures.Tests/IsExternalInitTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'IsExternalInitTest.CanBeCompiled()'

Check warning on line 7 in tests/dotnetCampus.LatestCSharpFeatures.Tests/IsExternalInitTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'IsExternalInitTest.CanBeCompiled()'

Check warning on line 7 in tests/dotnetCampus.LatestCSharpFeatures.Tests/IsExternalInitTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'IsExternalInitTest.CanBeCompiled()'

Check warning on line 7 in tests/dotnetCampus.LatestCSharpFeatures.Tests/IsExternalInitTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'IsExternalInitTest.CanBeCompiled()'
{
}
Expand Down
2 changes: 0 additions & 2 deletions tests/dotnetCampus.LatestCSharpFeatures.Tests/NullableTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,8 @@

namespace dotnetCampus.LatestCSharpFeatures.Tests;

[TestClass]
public class NullableTest

Check warning on line 5 in tests/dotnetCampus.LatestCSharpFeatures.Tests/NullableTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'NullableTest'

Check warning on line 5 in tests/dotnetCampus.LatestCSharpFeatures.Tests/NullableTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'NullableTest'

Check warning on line 5 in tests/dotnetCampus.LatestCSharpFeatures.Tests/NullableTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'NullableTest'
{
[TestMethod]
public void CanBeCompiled()

Check warning on line 7 in tests/dotnetCampus.LatestCSharpFeatures.Tests/NullableTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'NullableTest.CanBeCompiled()'

Check warning on line 7 in tests/dotnetCampus.LatestCSharpFeatures.Tests/NullableTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'NullableTest.CanBeCompiled()'
{
MemberNotNull();
Expand Down

This file was deleted.

2 changes: 0 additions & 2 deletions tests/dotnetCampus.LatestCSharpFeatures.Tests/RequiredTest.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
namespace dotnetCampus.LatestCSharpFeatures.Tests;

[TestClass]
public class RequiredTest

Check warning on line 3 in tests/dotnetCampus.LatestCSharpFeatures.Tests/RequiredTest.cs

View workflow job for this annotation

GitHub Actions / build

Missing XML comment for publicly visible type or member 'RequiredTest'
{
[TestMethod]
public void CanBeCompiled()
{
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,22 +1,16 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net7.0;net6.0;net5.0;netcoreapp3.1;net48</TargetFrameworks>
<ImplicitUsings>enable</ImplicitUsings>
<TargetFrameworks>net7.0;net6.0;net5.0;netcoreapp3.1;netcoreapp3.0;netstandard2.0;net48;net472;net471;net47;net462;net461;net46;net452;net451;net45;net40</TargetFrameworks>
<ImplicitUsings>disable</ImplicitUsings>
<Nullable>enable</Nullable>
<IsPackable>false</IsPackable>
<IsTestProject>true</IsTestProject>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
<PackageReference Include="MSTest.TestAdapter" Version="2.2.10" />
<PackageReference Include="MSTest.TestFramework" Version="2.2.10" />
<PackageReference Include="coverlet.collector" Version="3.2.0" />
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\..\src\dotnetCampus.LatestCSharpFeatures.Analyzer\dotnetCampus.LatestCSharpFeatures.Analyzer.csproj" OutputItemType="Analyzer" ReferenceOutputAssembly="false" />
<PackageReference Include="dotnetCampus.LatestCSharpFeatures.Source" Version="11.0.0-alpha03" />
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.3" PrivateAssets="all" />
</ItemGroup>

</Project>

0 comments on commit 634bcba

Please sign in to comment.