คำถามในหัวข้อ 'stackalloc'
C # ส่งคืนตัวชี้ที่สร้างด้วย stackalloc ภายในฟังก์ชัน
ฉันมีรหัส C# ที่โต้ตอบกับรหัส C++ ซึ่งดำเนินการกับสตริง
ฉันมีโค้ดชิ้นนี้ในคลาสตัวช่วยแบบคงที่:
internal static unsafe byte* GetConstNullTerminated(string text, Encoding encoding)
{
int charCount = text.Length;
fixed (char* chars =...
1611 มุมมอง
schedule
15.12.2023