Thread overview
Propose to replace cyclic dependency error msg
December 06
Hi!

Just want to propose to replace compiler message from:

"Cyclic dependency between module xxx and yyy"

by

"Cyclic dependency between module ctors/dtors xxx and yyy"

Several times faced with the fact that people do not understand that compiler talking about constructors and they try to solve the nonexistent problem of looped import.
December 06
On Thu, Dec 06, 2018 at 05:03:08PM +0000, Denis Feklushkin via Digitalmars-d wrote:
> Hi!
> 
> Just want to propose to replace compiler message from:
> 
> "Cyclic dependency between module xxx and yyy"
> 
> by
> 
> "Cyclic dependency between module ctors/dtors xxx and yyy"
> 
> Several times faced with the fact that people do not understand that compiler talking about constructors and they try to solve the nonexistent problem of looped import.

Excellent proposal!  I filed a bug for this:

	https://issues.dlang.org/show_bug.cgi?id=19468


T

-- 
Insanity is doing the same thing over and over again and expecting different results.
December 06
On 12/6/18 1:36 PM, H. S. Teoh wrote:
> On Thu, Dec 06, 2018 at 05:03:08PM +0000, Denis Feklushkin via Digitalmars-d wrote:
>> Hi!
>>
>> Just want to propose to replace compiler message from:
>>
>> "Cyclic dependency between module xxx and yyy"
>>
>> by
>>
>> "Cyclic dependency between module ctors/dtors xxx and yyy"
>>
>> Several times faced with the fact that people do not understand that
>> compiler talking about constructors and they try to solve the
>> nonexistent problem of looped import.
> 
> Excellent proposal!  I filed a bug for this:
> 
> 	https://issues.dlang.org/show_bug.cgi?id=19468
> 
> 

Is there really a compiler message that says this? I thought all the cyclic dependency checking is done at runtime?

In any case, I agree the message should be clearer.

-Steve
December 06
On Thu, Dec 06, 2018 at 01:43:53PM -0500, Steven Schveighoffer via Digitalmars-d wrote:
> On 12/6/18 1:36 PM, H. S. Teoh wrote:
> > On Thu, Dec 06, 2018 at 05:03:08PM +0000, Denis Feklushkin via Digitalmars-d wrote:
> > > Hi!
> > > 
> > > Just want to propose to replace compiler message from:
> > > 
> > > "Cyclic dependency between module xxx and yyy"
> > > 
> > > by
> > > 
> > > "Cyclic dependency between module ctors/dtors xxx and yyy"
> > > 
> > > Several times faced with the fact that people do not understand that compiler talking about constructors and they try to solve the nonexistent problem of looped import.
> > 
> > Excellent proposal!  I filed a bug for this:
> > 
> > 	https://issues.dlang.org/show_bug.cgi?id=19468
> > 
> > 
> 
> Is there really a compiler message that says this? I thought all the cyclic dependency checking is done at runtime?
[...]

Argh, you're right. I should've checked before filing the bug. :D

In any case, it's a trivial fix:

	https://github.com/dlang/druntime/pull/2397


T

-- 
I am a consultant. My job is to make your job redundant. -- Mr Tom
December 06
On Thursday, 6 December 2018 at 18:56:23 UTC, H. S. Teoh wrote:

>
> Argh, you're right. I should've checked before filing the bug. :D
>
> In any case, it's a trivial fix:
>
> 	https://github.com/dlang/druntime/pull/2397
>
>
> T

Great! Thanks! ^^