Groups | Blog | Home
all groups > c# > september 2003 >

c# : Default type access modifier


Jacob N. Rohde
9/23/2003 11:14:50 PM
Hi guys,

I was under the assumption that the default type access modifier for
classes/structs is internal. But the MCAD Study Guide (from MS even) says
public?!?! (The Dr. GUI .NET tutorial from MS's site says internal!!)

So which source from MS do I believe? It is internal is it not?

Thanks

Jon Skeet
9/24/2003 8:23:19 AM
[quoted text, click to view]

It's internal, or private for nested classes, according to the spec. To
test out the practice, just compile a small class and look at the
resulting assembly with ildasm or Lutz Roeder's Reflector.

--
Jon Skeet - <skeet@pobox.com>
http://www.pobox.com/~skeet
AddThis Social Bookmark Button