Return-Path: X-Original-To: apmail-commons-issues-archive@minotaur.apache.org Delivered-To: apmail-commons-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id B5EA29349 for ; Mon, 6 Feb 2012 16:42:23 +0000 (UTC) Received: (qmail 40778 invoked by uid 500); 6 Feb 2012 16:42:23 -0000 Delivered-To: apmail-commons-issues-archive@commons.apache.org Received: (qmail 40645 invoked by uid 500); 6 Feb 2012 16:42:22 -0000 Mailing-List: contact issues-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: issues@commons.apache.org Delivered-To: mailing list issues@commons.apache.org Received: (qmail 40631 invoked by uid 99); 6 Feb 2012 16:42:22 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Feb 2012 16:42:22 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Feb 2012 16:42:20 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 67416CBC5B for ; Mon, 6 Feb 2012 16:41:59 +0000 (UTC) Date: Mon, 6 Feb 2012 16:41:59 +0000 (UTC) From: "Thomas Neidhart (Commented) (JIRA)" To: issues@commons.apache.org Message-ID: <1120889562.2536.1328546519424.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <600888451.2106.1328537399084.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Commented] (SANDBOX-388) Generic Type inference doesn't work in Eclipse MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/SANDBOX-388?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13201384#comment-13201384 ] Thomas Neidhart commented on SANDBOX-388: ----------------------------------------- A rather ugly but working solution would be to cast the input graph to an unchecked DirectedGraph to circumvent type inference at all, like the following: {code:title=FordFulkersonTest.java|borderStyle=solid} @Test(expected=NullPointerException.class) public void testNullGraphAndVertices() { findMaxFlow( (DirectedGraph) null ).from( null ).to( null ).applyingFordFulkerson( new IntegerWeight() ); } {code} > Generic Type inference doesn't work in Eclipse > ---------------------------------------------- > > Key: SANDBOX-388 > URL: https://issues.apache.org/jira/browse/SANDBOX-388 > Project: Commons Sandbox > Issue Type: Bug > Components: Graph > Environment: Eclipse Java EE IDE for Web Developers. > Version: Indigo Service Release 1 > Build id: 20110916-0149 > Reporter: Simone Tripodi > Priority: Blocker > > {{Flow}} and {{MST}} EDSL is affected by generic type inference issue, it simply doesn't work in Eclipse. It works in IDEA, but in the Eclipse forum they reported that doesn't work if the code is compiled with Oracle JDK7. > One of the reported error in Eclipse is: > {quote} > Type mismatch: cannot convert from SpanningTree,Object> to SpanningTree,Double> > {quote} > Looking for a solution -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira