Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 38A39200BA4 for ; Fri, 30 Sep 2016 23:40:22 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 37598160AB4; Fri, 30 Sep 2016 21:40:22 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id AB351160AE5 for ; Fri, 30 Sep 2016 23:40:21 +0200 (CEST) Received: (qmail 75894 invoked by uid 500); 30 Sep 2016 21:40:20 -0000 Mailing-List: contact notifications-help@groovy.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@groovy.apache.org Delivered-To: mailing list notifications@groovy.apache.org Received: (qmail 75650 invoked by uid 99); 30 Sep 2016 21:40:20 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 30 Sep 2016 21:40:20 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 9B7612C2A68 for ; Fri, 30 Sep 2016 21:40:20 +0000 (UTC) Date: Fri, 30 Sep 2016 21:40:20 +0000 (UTC) From: "ASF GitHub Bot (JIRA)" To: notifications@groovy.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (GROOVY-7930) @SelfType in hierarchy with an interface in the middle MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Fri, 30 Sep 2016 21:40:22 -0000 [ https://issues.apache.org/jira/browse/GROOVY-7930?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15537156#comment-15537156 ] ASF GitHub Bot commented on GROOVY-7930: ---------------------------------------- Github user asfgit closed the pull request at: https://github.com/apache/groovy/pull/428 > @SelfType in hierarchy with an interface in the middle > ------------------------------------------------------ > > Key: GROOVY-7930 > URL: https://issues.apache.org/jira/browse/GROOVY-7930 > Project: Groovy > Issue Type: Bug > Components: Compiler > Affects Versions: 2.4.7 > Reporter: Daniil Ovchinnikov > > {code} > interface Self { > def bar() > } > @SelfType(Self) > trait T { > def foo() { > println "foo called" > bar() > } > } > interface Middle extends T {} > class C implements Middle {} > new C().foo() > {code} > Above code compiles fine but fails at run time with: > {noformat} > groovy.lang.MissingMethodException: No signature of method: selftype.baseinterface.C.bar() is applicable for argument types: () values: [] > {noformat} > The compilation should fail like if {{Middle}} was a trait. -- This message was sent by Atlassian JIRA (v6.3.4#6332)