New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NPE when using varargs in mapping method #1541
Comments
I started analyzing this issue and I was able to move from the mentioned exception to the next one which looks harder to solve: The implementation doesn't generate a varargs parameter which is (at least für the eclipse compiler, jdk seems to be ok) required. But I am not able to find in the available API a way to detect if the given There is a Does someone have an idea how we could know that it is a varargs parameter? I guess we need to store this information and when generating the code decide if we should generate |
I did not analyse the issue.. But do we need to know if it is a vargarg? What happens if we treat it as array? Is this the reason of the NPE? I'm not in favour of using JDK / Eclipse internal methods. We do this, but only if a compiler does not comply to spec (I think we have something for Eclipse). In most cases , newer versions of the compilers will fix these issues. And when we go to java 8 only, it might be possible to remove that again. |
The eclipse compiler doesn't allow to override a varargs method using an array... the jdk compiler isn't complaining... 😢 And I am totally with you, try to never use internal methods |
Ah, the I checked so many types and the values they had stored in the debugger .. but missed this one the whole time... so now I am one step further. |
When I was reading the emails yesterday evening I was like I have seen |
…text varargs tests and fix issue
…text varargs tests and fix issue
Fixed with PR #1550 |
From this SO question.
The mapping:
Stacktrace:
The text was updated successfully, but these errors were encountered: