1
vote
6answers
2k views

Static classes and/or singletons — How many does it take to become a code smell? [closed]

In my projects I use quite a lot of static classes. These are usually classes that naturally seem to fit into a single-instance type of thing. Many times I use static classes and recently I've started ...
12
votes
5answers
909 views

What to say to your boss if they want you to use a global variable

I am currently 4 months into an internship, and when reviewing my code, my boss didn't like that I had kept a specific object local to a number of methods across a few separate classes within one ...