Skip to content

[1.38] Regression: cannot determine resolution for the derive macro Debug #63893

Closed
@petrochenkov

Description

@petrochenkov

#63628 (comment)

cannot determine resolution for the derive macro Debug

./reg/ruroonga_command/0.3.4/beta-2019-08-13.txt:[INFO] [stderr] error: cannot determine resolution for the derive macro `Debug`

Minimized:

use Enum::Debug;

#[derive(Debug)] // Add some more derives if the error does not reproduce
enum Enum {
    Debug
}

This is a regression from #63248, and #63867 works in the same direction but hasn't landed yet.

Basically, the import is blocked until the derive is expanded and the derive is blocked until the import is resolved, so we have a deadlock.

This worked previously, because we did some things in less principled way (textual comparisons instead of resolution), which allowed us to produce the enum earlier, before resolving the Debug, but now we need to resolve it before producing the Enum.

This is fixable in principle, by making the expansion infra more fine-grained (introducing some new "resolved, but not yet ready for expansion" states), but I'm afraid that's not something that could be backported to beta.
So, I'd say wontfix. Unfortunate, but seems acceptable given the number of affected crates (one regression found).

Metadata

Metadata

Assignees

No one assigned

    Labels

    T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.T-langRelevant to the language team, which will review and decide on the PR/issue.regression-from-stable-to-betaPerformance or correctness regression from stable to beta.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions