2011/7/9 Rafael Ávila de Espíndola <rafael.espindola at gmail.com>:>> It looks like we need to have opaque function types? Or we need to defer >> emission of some types until we've finished the translation unit. > > We were deferring this before, no? We could not produce a function type > taking an opaque type. Once it go resolved we would need to revisit the > function type. > > Maybe it is just the logic for delaying it that got broken in the > transition?What we were doing before is that if a function type depended on an incomplete type, the function type itself was made opaque, and subsequently resolved when the type(s) it depended on were completed. I haven't looked at the committed version closely, but the draft patches basically ripped out that code because the approach was unworkable. -Eli
I'm sorry, I've been away from the computer. I'll investigate this in the next half hour. Thanks for the test cases! -Chris On Jul 9, 2011, at 3:27 PM, Eli Friedman <eli.friedman at gmail.com> wrote:> 2011/7/9 Rafael Ávila de Espíndola <rafael.espindola at gmail.com>: >>> It looks like we need to have opaque function types? Or we need to defer >>> emission of some types until we've finished the translation unit. >> >> We were deferring this before, no? We could not produce a function type >> taking an opaque type. Once it go resolved we would need to revisit the >> function type. >> >> Maybe it is just the logic for delaying it that got broken in the >> transition? > > What we were doing before is that if a function type depended on an > incomplete type, the function type itself was made opaque, and > subsequently resolved when the type(s) it depended on were completed. > I haven't looked at the committed version closely, but the draft > patches basically ripped out that code because the approach was > unworkable. > > -Eli > > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
On Sat, Jul 9, 2011 at 4:27 PM, Chris Lattner <clattner at apple.com> wrote:> I'm sorry, I've been away from the computer. I'll investigate this in the next half hour. Thanks for the test cases!One more testcase, which might be of interest; crashes clang on x86-64: struct T { struct T (*p)(void); } t; -Eli
Possibly Parallel Threads
- [LLVMdev] type-system-rewrite branch landing tomorrow
- [LLVMdev] type-system-rewrite branch landing tomorrow
- [LLVMdev] type-system-rewrite branch landing tomorrow
- [LLVMdev] type-system-rewrite branch landing tomorrow
- [LLVMdev] type-system-rewrite branch near landing