Community
cancel
Showing results for 
Search instead for 
Did you mean: 
vzecca
Beginner
229 Views

// icpx ICE on illegal code in HandleDestructionImpl

The following illegal code provokes an ICE in icpx Version 2021.1 NextGen Beta Build 20200304

Even though the code is illegal the compiler should not crash but give a meaningful error message and end quietly.

 

// icpx ICE on illegal code in HandleDestructionImpl
union b; // this is illegal

struct S {
template <typename>
void a()
try {
} catch (int ()
noexcept (({ union b a; true; })))
{
}
};

 

Labels (1)
0 Kudos
4 Replies
RahulV_intel
Moderator
205 Views

Hi,

 

On compiling your code snippet with the latest build, I could see the following error messages.

bug_union.cpp:8:22: error: variable has incomplete type
      'union b'
noexcept (({ union b a; true; })))
                     ^
bug_union.cpp:1:7: note: forward declaration of 'b'
union b; // this is illegal
      ^
1 error generated.
compilation aborted for bug_union.cpp (code 1)

 

Looks like this issue is fixed in the latest ICPX build (icpx (ICX) 2021.1 Beta 20200715).

 

Could you upgrade to the latest build and try?

 

Thanks,

Rahul

 

RahulV_intel
Moderator
193 Views

Hi,


Let me know if I can close this thread from my end.


Thanks,

Rahul


vzecca
Beginner
191 Views

Yes, please close it.

RahulV_intel
Moderator
190 Views

Thanks for the confirmation.

Intel will no longer monitor this thread. Henceforth, any further discussion on this thread will be considered as a community response.


Reply