mirror of
https://github.com/rust-lang/cargo.git
synced 2025-09-25 11:14:46 +00:00
refactor(add): Pull out feature count for reuse
This commit is contained in:
parent
1f34b007e8
commit
4a0b8948dd
@ -43,6 +43,8 @@ use crate::CargoResult;
|
||||
use crate::GlobalContext;
|
||||
use crate_spec::CrateSpec;
|
||||
|
||||
const MAX_FEATURE_PRINTS: usize = 30;
|
||||
|
||||
/// Information on what dependencies should be added
|
||||
#[derive(Clone, Debug)]
|
||||
pub struct AddOptions<'a> {
|
||||
@ -1114,7 +1116,6 @@ fn print_dep_table_msg(shell: &mut Shell, dep: &DependencyUI) -> CargoResult<()>
|
||||
|
||||
writeln!(stderr, "{prefix}Features{suffix}:")?;
|
||||
|
||||
const MAX_FEATURE_PRINTS: usize = 30;
|
||||
let total_activated = activated.len();
|
||||
let total_deactivated = deactivated.len();
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user