MCUXPRESSO C++ Project Using std Namespace

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

MCUXPRESSO C++ Project Using std Namespace

1,414件の閲覧回数
pwhittin
Contributor I

With MCUXPRESSO create a C++ project with access to the 'std' name space

I've followed the 'File -> New -> Project' wizard, accepted all defaults, and created a C++ project with MCUXPRESSO version mcuxpressoide-10.1.1_606 named 'LPC54608J512_Project'.  The project generated compiles, and links without error.

I then replace the blank line 44 with:

std::size_t haha = 0;

and compiling fails with the following error:

../source/LPC54608J512_Project.cpp:44:6: error: 'size_t' in namespace 'std' does not name a type

Any ideas?

1 返信

1,278件の閲覧回数
pwhittin
Contributor I

I figured it out!  One must include:

#include <cstddef>