3 ms·
>structs are often frowned on Only in the premature optimization sense, and "familiarity with new programmers" sense. There's nothing wrong with using structs.
by Arnavion 12y ago
>structs are often frowned on
Only in the premature optimization sense, and "familiarity with new programmers" sense. There's nothing wrong with using structs. In fact, XNA and many other game programming libraries do use structs to represent position vectors, which is the context of this article.
>And arrays are reference types too, so things like string.split have no workaround.
If you're okay with going unsafe, arrays can be stackalloc'd.