Intel® C++ Compiler
Community support and assistance for creating C++ code that runs on platforms based on Intel® processors.

Class data member initialization

Deepak_Chandan
Beginner
924 Views

Hi,

When I compile a class that has a data member initialized within the class header file, I get an error that says "data member initializer is not allowed". I get this error even after supplying -std=c++11 flag to the compiler. My understanding is that such an initialization should be allowed in c++11 and infact gcc 4.7 on my computer does allow such initialization with the same flag. Is this feature not supported in Intel compiler version 13? 

Thanks,

Deepak

0 Kudos
3 Replies
Georg_Z_Intel
Employee
924 Views
Hello Deepak, you seem to speak about non-static data members. No, we don't support this yet. I've asked engineering about our plans. I'm coming back to you if I learn more. Best regards, Georg Zitzlsberger
0 Kudos
Georg_Z_Intel
Employee
924 Views
Hello Deepak, the next (first) update will have support for it: Intel(R) Composer XE 2013 Update 1 Best regards, Georg Zitzlsberger
0 Kudos
Deepak_Chandan
Beginner
924 Views
Hi Georg, Yes, I meant non-static data member. Thanks for the information, I look forward to the next update. -Deepak
0 Kudos
Reply