internal error: assertion failed: lower_constant: bad kind (shared/cfe/edgcpfe/lower_il.c, line 5315)

internal error: assertion failed: lower_constant: bad kind (shared/cfe/edgcpfe/lower_il.c, line 5315)

 % cat test.ii
extern "C" typedef
bool (*IsAcceptableThis) (const int &v);
typedef bool (*NativeImpl) (int *, int);
template < IsAcceptableThis, NativeImpl > void CallNonGenericMethod ();
typedef int (*JSNative) (int *, unsigned, int *);
typedef struct
{
    JSNative op;
}
JSNativeWrapper;
struct A
{
    JSNativeWrapper a;
};
struct B
{
};
template < typename NativeType > class C:B
{
public:
    NativeType ThisType;
    typedef C ThisTypeArray;
    static bool IsThisClass (const int &v);
    static bool fun_subarray_impl (int *, int);
    static int fun_subarray (int *, unsigned, int *)
    {
        CallNonGenericMethod < ThisTypeArray::IsThisClass,
                             ThisTypeArray::fun_subarray_impl > ();
        return 0;
    }
};
class D:public C < int >
{
};
A a[] = { D::fun_subarray };

 % icpc test.ii
test.ii(4): internal error: assertion failed: lower_constant: bad kind (shared/cfe/edgcpfe/lower_il.c, line 5315)
  template < IsAcceptableThis, NativeImpl > void CallNonGenericMethod ();
                                                 ^
compilation aborted for test.ii (code 4)
 % icpc -v
icpc version 13.0.0 (gcc version 4.7.0 compatibility)

2 posts / 0 nouveau(x)
Dernière contribution
Reportez-vous à notre Notice d'optimisation pour plus d'informations sur les choix et l'optimisation des performances dans les produits logiciels Intel.

Thank you for reporting this and providing a small example.

I have entered this in our bug tracking database as DPD200236114 and will try to fix it as soon as possible.

One possible workaround is to make the static member functions IsThisClass and fun_subarray_impl global functions instead (of course this might require allowing greater access on some of your member data).

Sorry for the inconvenience.

Judy

Connectez-vous pour laisser un commentaire.