global declaration within anything outside the mainscope shouldn't be possible at all.
What do you mean by mainscope? Globals inside types are very useful, if you want all types to share certain information (for example, if you have a button class, and you want a function that returns the last button clicked regardless of what button you query).