Menu

#332 Checkstyle does not support "diamond" Java 7 syntax

5.0.0
closed
nobody
None
5
2014-10-03
2011-10-03
No

Suppose this code snippet:

import java.util.HashMap;
import java.util.Map;

public class Test {
public static void main(String[] args) {
Map<String, String=""> map = new HashMap<>();

}

}

Checkstyle 5.4.1 will fail with:
Got an exception - expecting EOF, found '}'

eclipse-cs ver: 5.4.1.201109192037
Eclipse ver: Indigo Service Release 1
JDK: 1.7.0

Discussion

  • Lars Koedderitzsch

    Checkstyle core does not support Java 7 yet.

     
  • Vladimir Lalov

    Vladimir Lalov - 2011-10-04

    Is a Java 7 support on the Checkstyle roadmap?

     
  • Lars Koedderitzsch

    That would depend on the Checkstyle core project (http://checkstyle.sf.net), but as far as I understand their mailing list traffic it is in the works...

     
  • Vladimir Lalov

    Vladimir Lalov - 2011-10-05

    This is good enough for me. Thank you.

     
  • Michael

    Michael - 2011-11-06

    Checkstyle 5.5 with Java 7 support was released a few days ago:
    http://checkstyle.sourceforge.net/releasenotes.html

    Could this issue therefore please be reopened?

     

Log in to post a comment.