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

Make all assemblies CLS Compliant #396

Merged
merged 3 commits into from
Jan 24, 2020
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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

[assembly: System.CLSCompliant(true)]
namespace Microsoft.Data
{
/// <include file='..\..\..\..\doc\snippets\Microsoft.Data\OperationAbortedException.xml' path='docs/members[@name="OperationAbortedException"]/OperationAbortedException/*' />
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

[assembly: System.CLSCompliant(true)]
namespace Microsoft.Data
{
/// <include file='..\..\..\..\doc\snippets\Microsoft.Data\OperationAbortedException.xml' path='docs/members[@name="OperationAbortedException"]/OperationAbortedException/*' />
[System.Serializable]
public sealed partial class OperationAbortedException : System.SystemException
{
internal OperationAbortedException() { }

private OperationAbortedException(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context) { }

}
}
namespace Microsoft.Data.Sql
Expand All @@ -27,6 +31,7 @@ public sealed partial class SqlNotificationRequest
public string UserData { get { throw null; } set { } }
}
}

namespace Microsoft.Data.SqlClient
{
/// <include file='../../../../doc/snippets/Microsoft.Data.SqlClient/ApplicationIntent.xml' path='docs/members[@name="ApplicationIntent"]/ApplicationIntent/*'/>
Expand Down Expand Up @@ -1315,9 +1320,12 @@ public sealed partial class SqlErrorCollection : System.Collections.ICollection,
public System.Collections.IEnumerator GetEnumerator() { throw null; }
}
/// <include file='../../../../doc/snippets/Microsoft.Data.SqlClient/SqlException.xml' path='docs/members[@name="SqlException"]/SqlException/*'/>
[System.Serializable]
public sealed partial class SqlException : System.Data.Common.DbException
{
internal SqlException() { }
private SqlException(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context) { }

/// <include file='../../../../doc/snippets/Microsoft.Data.SqlClient/SqlException.xml' path='docs/members[@name="SqlException"]/Class/*'/>
public byte Class { get { throw null; } }
/// <include file='../../../../doc/snippets/Microsoft.Data.SqlClient/SqlException.xml' path='docs/members[@name="SqlException"]/ClientConnectionId/*'/>
Expand Down Expand Up @@ -1708,10 +1716,14 @@ public interface IBinarySerialize
/// <include file='../../../../doc/snippets/Microsoft.Data.SqlClient.Server/IBinarySerialize.xml' path='docs/members[@name="IBinarySerialize"]/Write/*'/>
void Write(System.IO.BinaryWriter w);
}

/// <include file='../../../../doc/snippets/Microsoft.Data.SqlClient.Server/InvalidUdtException.xml' path='docs/members[@name="InvalidUdtException"]/InvalidUdtException/*'/>
[System.Serializable]
public sealed partial class InvalidUdtException : System.SystemException
{
internal InvalidUdtException() { }
private InvalidUdtException(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context) { }

}
/// <include file='../../../../doc/snippets/Microsoft.Data.SqlClient.Server/SqlDataRecord.xml' path='docs/members[@name="SqlDataRecord"]/SqlDataRecord/*'/>
public partial class SqlDataRecord : System.Data.IDataRecord
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,19 @@
<AssemblyInfo Include="using System.Runtime.InteropServices%3B" />
<AssemblyInfo Include="using System.Runtime.Versioning%3B%0A" />

<AssemblyInfo Include="[assembly: System.CLSCompliantAttribute(true)]" />
<AssemblyInfo Include="[assembly: System.Runtime.InteropServices.ComVisibleAttribute(false)]" />
<AssemblyInfo Include="[assembly: System.Runtime.Versioning.TargetFrameworkAttribute(&quot;.NETFramework,Version=$(TargetFrameworkVersion)&quot;)]" />
<AssemblyInfo Include="[assembly: System.Resources.SatelliteContractVersion(&quot;$(AssemblyVersion)&quot;)]" />
<AssemblyInfo Include="[assembly: System.Reflection.AssemblyTitleAttribute(&quot;$(AssemblyName)&quot;)]" />
<AssemblyInfo Include="[assembly: System.Reflection.AssemblyDescriptionAttribute(&quot;$(Description)&quot;)]" />
<AssemblyInfo Include="[assembly: System.Reflection.AssemblyCompanyAttribute(&quot;$(Company)&quot;)]" />
<AssemblyInfo Include="[assembly: System.Reflection.AssemblyProductAttribute(&quot;$(Product)&quot;)]" />
<AssemblyInfo Include="[assembly: System.Reflection.AssemblyCopyrightAttribute(&quot;$(Copyright)&quot;)]" />
<AssemblyInfo Include="[assembly: System.Reflection.AssemblyVersionAttribute(&quot;$(AssemblyVersion)&quot;)]" />
<AssemblyInfo Include="[assembly: System.Reflection.AssemblyFileVersionAttribute(&quot;$(AssemblyFileVersion)&quot;)]" />
<AssemblyInfo Include="[assembly: System.Reflection.AssemblyInformationalVersionAttribute(&quot;$(Version)&quot;)]" />
<AssemblyInfo Include="[assembly: System.Reflection.AssemblyConfigurationAttribute(&quot;$(Configuration)&quot;)]" />
<AssemblyInfo Include="[assembly: CLSCompliant(true)]" />
<AssemblyInfo Include="[assembly: ComVisible(false)]" />
<AssemblyInfo Include="[assembly: TargetFramework(&quot;.NETFramework,Version=$(TargetFrameworkVersion)&quot;)]" />
<AssemblyInfo Include="[assembly: SatelliteContractVersion(&quot;$(AssemblyVersion)&quot;)]" />
<AssemblyInfo Include="[assembly: AssemblyTitle(&quot;$(AssemblyName)&quot;)]" />
<AssemblyInfo Include="[assembly: AssemblyDescription(&quot;$(Description)&quot;)]" />
<AssemblyInfo Include="[assembly: AssemblyCompany(&quot;$(Company)&quot;)]" />
<AssemblyInfo Include="[assembly: AssemblyProduct(&quot;$(Product)&quot;)]" />
<AssemblyInfo Include="[assembly: AssemblyCopyright(&quot;$(Copyright)&quot;)]" />
<AssemblyInfo Include="[assembly: AssemblyVersion(&quot;$(AssemblyVersion)&quot;)]" />
<AssemblyInfo Include="[assembly: AssemblyFileVersion(&quot;$(AssemblyFileVersion)&quot;)]" />
<AssemblyInfo Include="[assembly: AssemblyInformationalVersion(&quot;$(Version)&quot;)]" />
<AssemblyInfo Include="[assembly: AssemblyConfiguration(&quot;$(Configuration)&quot;)]" />
</ItemGroup>
<MakeDir Directories="$(IntermediateOutputPath)" />
<WriteLinesToFile File="$(IntermediateOutputPath)$(AssemblyName).AssemblyInfo.cs" Overwrite="True" Lines="@(AssemblyInfo)" />
Expand Down
1 change: 1 addition & 0 deletions tools/targets/GenerateThisAssemblyCs.targets
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
BeforeTargets="CoreCompile">
<PropertyGroup>
<ThisAssemblyCsContents>
[assembly: System.CLSCompliant(true)]
namespace System
{
internal static class ThisAssembly
Expand Down