Fork Me On Github

c# 重写 c++ 程序笔记:数据初始化

std::uint32_t 初始化

c++ 数组定义

std::array<std::uint32_t, 7> data;

转成c# 数组


var data = new uint[7];

for (int i = 0; i < 7; i++)
{
    data[i] = 0xcccccccc;
}

std::uint8_t 初始化

c++ 数组定义

std::array<std::uint8_t, 7> data;

转成c# 数组


var data = new byte[7];

for (int i = 0; i < 7; i++)
{
    data[i] = 0xcc;
}
点击查看全文
0 43 0