sneaky intentions bug...
Here's a fun one:
Integer.intValue() + "-" + 12
The single char string to char intention will helpfully suggest you replace the "-" with '-', which would, potentially, cause a showstopper bug, a highly agitated QA guy, an escalated issue, and about two hours of pouring through utterly unrelated code to find.
Intentions powers that be (that'd be Dave), please fix!
Please sign in to leave a comment.
Hello Hani,
Hani Suleiman wrote:
Unfortunately that does not compile and I see no intention...
I am currently unable to reproduce your problem. Which IDEA build are
you using? Perhaps a new example will help me, or even better a JIRA
request.
There are more powers these days;-)
Bas
Ok, my bad. (btw, I was using Integer.intValue() as an example, actual code is something like new Integer("20").intValue()
Anyway, I tried to create a testcase and the intention correctly doesn't suggest that a single char string concated to a bunch of primitives be converted to a char, and instead only suggests the second instance of the string is converted.
Time to hunt down the rogue developer who took matters in their own hands instead of trusting the intention and administering a beating.
Hani Suleiman wrote:
Yep, it does. Of course I already knew this was working perfectly.
I hope they were sufficiently punished. Perhaps he or she used some
other static analysis tool?;-)
Bas