Should enums in C# have their own file? [closed]

I have a class which uses an enumeration, the enum is currently in its own file which seems wasteful.

What is the general opinion on enums being placed within the namespace of a file that they are consumed in? Or should the enum really live in its own cs file?

Edit

I should mention that while the class in question uses these enumerations, so does external callers. In other words, another class can set these enumerations. So they are not used internally to the class, otherwise this question would be a no brainer.

15 Answers
15

Leave a Comment