Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the significance of System.CLSCompliantAttribute?

Tags:

.net

I have gone through this article http://msdn.microsoft.com/en-us/library/system.clscompliantattribute.aspx and would like to understand its real significance.

When should you make this false?

Also, what are the pitfalls of not marking it explicitly?

I am mainly asking this question because of the design warning which you can read here... http://msdn.microsoft.com/en-us/library/ms182156.aspx

I want to understand, how can "not marking a library complaint" negatively impact me in any way.

like image 993
Rahul Soni Avatar asked Jan 27 '12 05:01

Rahul Soni


1 Answers

C# supports some features that are not CLS compliant, including pointers, unsigned numeric types, public names that only differ by case, and others.

Public members exposing such features must not be [CLSCompliant(true)].

like image 90
SLaks Avatar answered Oct 23 '22 03:10

SLaks