摘要:
一般情况,C#数组仅支持2GB大小,对于int[]来讲,大概就是:2*1024*1024*1024/4=530870912,但实际上 比这个数值略小。 int bb = 536870897; while (true) { bb++; try { int[] aa = new int[bb]; } c 阅读全文
摘要:
[StructLayout(LayoutKind.Sequential,Pack =1)]//Pack此时设为1 public struct MyStrct { public float a; public float b; public float c; public float d; byte 阅读全文
摘要:
var fileStream = new FileStream(@"F:\xx.txt", FileMode.Open, FileAccess.Read, FileShare.None//可以确保该文件在打开期间,再打开会报错! ); var fileStreamA = new FileStream 阅读全文