Kir*_*kow 0 java eclipse java-8 sonarlint sonarlint-eclipse
当它要求时,Eclipse意味着什么Replace the type specification in this constructor call with the diamond operator ('<>'),因为所述运算符已经存在?
然后我将光标放在带蓝色下划线的内容上,然后按下F2以了解更多内容,我收到此消息(Replace the type specification in this constructor call with the diamond operator ('<>')):
如果我Object从内部删除<>,Eclipse仍然不高兴:
我们确保了
java.util.List 是进口的 Project -> Clean... 命令已应用蓝色警告仍然不会消失.
这似乎是一个在错误的SonarLint的钻石运营商检查,不属于Eclipse JDT:见SonarLint的源代码包含的信息.
另请参阅:SonarJava规则2293:应使用菱形运算符("<>")
解:
禁用的SonarJava规则2293,并使用了Eclipse的警告 泛型类型>冗余类型参数(1.7或更高版本)来代替.
| 归档时间: |
|
| 查看次数: |
5508 次 |
| 最近记录: |