www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - valid interface hierarchy rejected by dmd 0.122

reply zwang <nehzgnaw gmail.com> writes:
dmd 0.122 reports: "Error: circular inheritance of interface"
while there is no circular inheritance in the following code:

<code>
interface A:B{}
interface B:C{}
interface C:D{}
interface D{}
</code>
May 04 2005
next sibling parent reply zwang <nehzgnaw gmail.com> writes:
zwang wrote:
 dmd 0.122 reports: "Error: circular inheritance of interface"
 while there is no circular inheritance in the following code:
 
 <code>
 interface A:B{}
 interface B:C{}
 interface C:D{}
 interface D{}
 </code>
A similar test case: <code> class A:B{} interface B:C{} interface C:D{} interface D{} </code>
May 04 2005
parent Thomas Kuehne <thomas-dloop kuehne.thisisspam.cn> writes:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

zwang schrieb am Thu, 05 May 2005 12:37:59 +0800:
 zwang wrote:
 dmd 0.122 reports: "Error: circular inheritance of interface"
 while there is no circular inheritance in the following code:
 
 <code>
 interface A:B{}
 interface B:C{}
 interface C:D{}
 interface D{}
 </code>
A similar test case: <code> class A:B{} interface B:C{} interface C:D{} interface D{} </code>
Added to DStress as http://dstress.kuehne.cn/compile/interface_20.d http://dstress.kuehne.cn/compile/interface_21.d Thomas -----BEGIN PGP SIGNATURE----- iD8DBQFCezYu3w+/yD4P9tIRAiYZAJ4tr7YkoHxPIIPDeJOIUnnZ/7YAGwCfZxzy XWe+qFMlTupcMxp/6+VNQzk= =uZx5 -----END PGP SIGNATURE-----
May 06 2005
prev sibling parent reply "Ben Hinkle" <ben.hinkle gmail.com> writes:
"zwang" <nehzgnaw gmail.com> wrote in message 
news:d5c7i4$c4i$1 digitaldaemon.com...
 dmd 0.122 reports: "Error: circular inheritance of interface"
 while there is no circular inheritance in the following code:

 <code>
 interface A:B{}
 interface B:C{}
 interface C:D{}
 interface D{}
 </code>
the following also fails to compile with circular inheritance error: interface A{} interface B:A{} interface C:B{} class Foo:C{} int main() { Foo x = new Foo; return 0; } so it looks like changing the order of defining the interfaces doesn't fix the issue.
May 08 2005
parent reply "Walter" <newshound digitalmars.com> writes:
"Ben Hinkle" <ben.hinkle gmail.com> wrote in message
news:d5lh1j$22hp$1 digitaldaemon.com...
 so it looks like changing the order of defining the interfaces doesn't fix
 the issue.
Right. But I have it fixed anyway in .123, which I hope to post soon.
May 08 2005
parent reply Peter Mackay <a_pointy_stick.NoJunkMail yahoo.co.uk> writes:
Walter wrote:
 "Ben Hinkle" <ben.hinkle gmail.com> wrote in message
 news:d5lh1j$22hp$1 digitaldaemon.com...
 
so it looks like changing the order of defining the interfaces doesn't fix
the issue.
Right. But I have it fixed anyway in .123, which I hope to post soon.
Cool, that's great to hear. :-) Sorry to be a pest, but would it be possible to get more information in this kind of error message? At the moment, I just get this: Error: circular inheritance of interface --- errorlevel 1 Which doesn't tell me where I went wrong. It's okayish because I know where I've been working recently, but I'd like to double click on the error and have my IDE jump to my problem, or for it to tell me which interfaces caused the problems so I could hunt them down myself. There are a few more errors I've encountered, which don't print file(line) formatted error messages. Peter
May 08 2005
parent "Walter" <newshound digitalmars.com> writes:
"Peter Mackay" <a_pointy_stick.NoJunkMail yahoo.co.uk> wrote in message
news:d5m8vr$2mtr$1 digitaldaemon.com...
 There are a few more errors I've encountered, which don't print
 file(line) formatted error messages.
That's getting better over time.
May 09 2005