substitute
new Span vs stackalloc
I'm working on a library that is able to read and write memory from a remote computer and was wondering which of these two is better practice?
I feel as though these would produce extremely if not exactly the same memory layouts, it creates a Span in both.
76 replies
❔ Is it possible to use a generic type as another type outside of the generic class w/o reflection?
Hi, in C++ we can write code like the following:
This effectively allows a special type-of-types to exist that only exists as a way of tying together types into a singular type (
tuple<i,j,k>
) while allowing access to the inner types i,j,k
at compile time.
I was wondering if there was an equivalent in C# that didn't require reflection.
In essence, I would like to do something like this
to later consume like
which does like
Thanks!139 replies