interface Foo { void work(); } template Wrapper(B, alias Func, int func) { alias typeof(&Func) FuncPtr; private static FuncPtr get_funcptr() { return func; } } int main(char[][] args) { auto x = new Wrapper!(Foo, Foo.work, cast(int)(Foo.classinfo.vtbl[0]))(); return 0; } Assertion failure: 'e1->type' on line 6377 in file 'expression.c' abnormal program termination
The code you posted is invalid. Replace "template Wrapper" with "class Wrapper" or "struct Wrapper". Added to DStress as http://dstress.kuehne.cn/compile/c/classinfo_02_A.d http://dstress.kuehne.cn/compile/c/classinfo_02_B.d
Fixed DMD 1.014
AltStyle によって変換されたページ (->オリジナル) / アドレス: モード: デフォルト 音声ブラウザ ルビ付き 配色反転 文字拡大 モバイル