我有一段時間以前寫過的代碼,而且現在我沒有那麼多'C++'。我在「Visual C++ 2010 Express」中編譯了沒有問題的代碼。我已經在vs2015中編譯了它,並且出現了'std :: array'錯誤。有人可以善意解釋我的錯誤嗎?std :: array和VS2015錯誤
這編譯「的Visual C++ 2010 Express的
// create arrays to hold port write data
array<DataChunk>^ dataArray = gcnew array<DataChunk>(1008);
但在vs2015與錯誤編譯OK:
1>c:\users\carl\desktop\pond control\pond control\Form1.h(1199): error C2976: 'std::array': too few template arguments
1> C:\Program Files\Microsoft Visual Studio 14.0\VC\include\utility(306): note: see declaration of 'std::array'
任何幫助將非常感激。
^或\ *:陣列 * dataArray中 –
911
嘗試:陣列; –
911