public static readonly OR public readonly static???

Neal

Forum Admin
Staff member
Joined
Apr 15, 2011
Messages
129
Location
VA
Programming Experience
10+
I tell ya, for a language that has such strict formatting such as the braces issue why the heck can't they standardize whether static becomes before or after the scope? I can have both public static readonly PropertyName and public readonly static PropertyName. Sloppy!
 

jmcilhinney

C# Forum Moderator
Staff member
Joined
Apr 23, 2011
Messages
3,209
Location
Sydney, Australia
Programming Experience
10+
Any imposed order would be arbitrary, so I guess they decided not to worry. I take my cue from VB, which does format for you and puts Shared before ReadOnly, so I always put 'public' or the like first, then 'static' and then 'readonly'.
 
Top Bottom