When would I need to use the stackalloc keyword in C#?

后端 未结 7 948
清歌不尽
清歌不尽 2021-02-05 04:25

What functionality does the stackalloc keyword provide? When and Why would I want to use it?

相关标签:
7条回答
  • 2021-02-05 04:53

    It is like Steve pointed out, only used in unsafe code context (e.g, when you want to use pointers).

    If you don't use unsafe code in your C# application, then you will never need this.

    0 讨论(0)
提交回复
热议问题