title: What's the deal with [ComVisible] default and public classes COM exposure?
body: <p>MSDN has <a href="http://msdn.microsoft.com/en-us/library/system.runtime.interopservices.comvisibleattribute.aspx" rel="noreferrer">this article about <code>[ComVisible]</code> attribute</a>. I don't quite get what happens when one sets <code>[ComVisible(true)]</code>.</p>
  
  <p>MSDN says</p>
  
  <blockquote>
    <p>The <strong>default is true</strong>, which indicates that the managed type is visible to COM. This attribute is not needed to make <strong>public managed assemblies</strong> and <strong>types visible</strong>; they are visible to COM by default. Only public types can be made visible.</p>
  </blockquote>
  
  <p>So they say public types are visible to COM by default. But they also say <em>only public types can be made visible</em> by setting <code>[ComVisible(true)]</code>. It does not makes sense: if public types are visible by default, then how does setting <code>[ComVisible(true)]</code> make public types visible? If they're already visible how will they get more visible?</p>
  
  <p>Perhaps my understanding is not correct. I shall appreciate if anyone can put some light on the above statements.</p>