pub enum ConflictReason {
    Semver,
    Links(InternedString),
    MissingFeatures(String),
    RequiredDependencyAsFeature(InternedString),
    NonImplicitDependencyAsFeature(InternedString),
    PublicDependency(PackageId),
    PubliclyExports(PackageId),
}
Expand description

All possible reasons that a package might fail to activate.

We maintain a list of conflicts for error reporting as well as backtracking purposes. Each reason here is why candidates may be rejected or why we may fail to resolve a dependency.

Variants§

§

Semver

There was a semver conflict, for example we tried to activate a package 1.0.2 but 1.1.0 was already activated (aka a compatible semver version is already activated)

The links key is being violated. For example one crate in the dependency graph has links = "foo" but this crate also had that, and we’re only allowed one per dependency graph.

§

MissingFeatures(String)

A dependency listed features that weren’t actually available on the candidate. For example we tried to activate feature foo but the candidate we’re activating didn’t actually have the feature foo.

§

RequiredDependencyAsFeature(InternedString)

A dependency listed a feature that ended up being a required dependency. For example we tried to activate feature foo but the candidate we’re activating didn’t actually have the feature foo it had a dependency foo instead.

§

NonImplicitDependencyAsFeature(InternedString)

A dependency listed a feature for an optional dependency, but that optional dependency is “hidden” using namespaced dep: syntax.

§

PublicDependency(PackageId)

pub dep error

§

PubliclyExports(PackageId)

Implementations§

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
This method returns an Ordering between self and other. Read more
Compares and returns the maximum of two values. Read more
Compares and returns the minimum of two values. Read more
Restrict a value to a certain interval. Read more
This method tests for self and other values to be equal, and is used by ==.
This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
This method returns an ordering between self and other values if one exists. Read more
This method tests less than (for self and other) and is used by the < operator. Read more
This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
This method tests greater than (for self and other) and is used by the > operator. Read more
This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
Compare self to key and return true if they are equal.

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Should always be Self
The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.

Layout§

Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference’s “Type Layout” chapter for details on type layout guarantees.

Size: 32 bytes

Size for each variant:

  • Semver: 0 bytes
  • Links: 16 bytes
  • MissingFeatures: 24 bytes
  • RequiredDependencyAsFeature: 16 bytes
  • NonImplicitDependencyAsFeature: 16 bytes
  • PublicDependency: 8 bytes
  • PubliclyExports: 8 bytes