-
Notifications
You must be signed in to change notification settings - Fork 101
Compile errors when defining nested buildable types in generic outer classes #268
Comments
Argh. Generics. Thanks for the report, I'll try and get on this tomorrow :) |
Hi @tullisar. I'm unable to reproduce this bug with the example code you've given. What version of FreeBuilder are you on? What version of Java, and what build system? Did you accidentally remove some part of your code that triggers the bug in condensing it for this report? |
Freebuilder Version: 1.14.6 Looking at this a bit more, using Eclipse to build seems to trigger this. When I run a Maven build it seems to be just fine. |
I'm starting to suspect this might be a regression in Eclipse? I never recalled having this bug until recently (on the same construct I've listed as causing the bug). On a whim I launched Eclipse Mars (4.5.1) and ran a build and it generated the code just fine. Since the maven build works I've just gone ahead and turn off Eclipse's automatic build for the time being. I'm not exactly sure what kind of bug report I'd even submit for Eclipse though. I'm not really familiar with annotation processors and how Eclipse interacts with them. |
I can work around most things in FreeBuilder's code, so let's see if I can repro now I know the IDE version. Thanks :) |
Yep, I can reproduce this now. (Irritatingly I can't reproduce it in a test, but I'll figure something out to try and avoid future regressions.) |
Sorry, @tullisar, I haven't got around to prioritising this yet. Hard to motivate myself to work around a niche Eclipse bug :( |
Defining a static buildable type in a generic outer class generates compiler errors when one of the fields is another nested class in the same file.
The following is a portion of what gets generated. Most of the references to
GenericOuterBug.Sibling
get generated asGenericOuterBug<T>.Sibling
:The text was updated successfully, but these errors were encountered: