When specifying a crate without a library target kind as a dependency, cargo currently just silently ignores it. For example:
[package]
name = "deptest"
version = "0.1.0"
edition = "2018"
[dependencies]
ripgrep = "*"
$ cargo run
Compiling deptest v0.1.0 (/tmp/deptest)
Finished dev [unoptimized + debuginfo] target(s) in 0.31s
Running `target/debug/deptest`
Hello, world!
Note that the dependency isn't even compiled. Clearly, Cargo has already decided to elide this crate in the dependency graph, but the cause is not obvious to the user. All this can be confusing if the user is expecting to be able to use the dependency. I think a warning message is in order.
When specifying a crate without a library target kind as a dependency, cargo currently just silently ignores it. For example:
Note that the dependency isn't even compiled. Clearly, Cargo has already decided to elide this crate in the dependency graph, but the cause is not obvious to the user. All this can be confusing if the user is expecting to be able to use the dependency. I think a warning message is in order.