Peter Duniho
5/22/2008 9:45:00 PM
On Thu, 22 May 2008 14:30:01 -0700, Mark <mmodrall@nospam.nospam> wrote:
> I know this is pretty esoteric but if all you have is a bunch of static
> methods, which is the most efficient - a struct or a static class? Or
> are
> they about the same?
I would not expect there to be any difference. However, inasmuch as the
C# programming reference suggests making a type a class if you expect it
to be something more than a very simple data structure, it seems to me
that a static class is generally a better choice than a static struct.
If you're never actually making an instance of the type though, I don't
think there should be any efficiency difference at all, one way or the
other.
Pete