fix: Box contents of an enum to make the variants close in size

Identified by clippy

https://rust-lang.github.io/rust-clippy/master/index.html#large_enum_variant
pull/24376/head
Carol (Nichols || Goulding) 2021-12-02 11:12:39 -05:00
parent 948a45a4ea
commit 7d4693ed8c
No known key found for this signature in database
GPG Key ID: E907EE5A736F87D4
1 changed files with 2 additions and 2 deletions

View File

@ -22,7 +22,7 @@ pub struct Config {
#[derive(Debug, StructOpt)] #[derive(Debug, StructOpt)]
enum Command { enum Command {
/// Dump preserved catalog. /// Dump preserved catalog.
DumpCatalog(dump_catalog::Config), DumpCatalog(Box<dump_catalog::Config>),
/// Prints what CPU features are used by the compiler by default. /// Prints what CPU features are used by the compiler by default.
PrintCpu, PrintCpu,
@ -30,7 +30,7 @@ enum Command {
pub async fn command(config: Config) -> Result<()> { pub async fn command(config: Config) -> Result<()> {
match config.command { match config.command {
Command::DumpCatalog(dump_catalog) => dump_catalog::command(dump_catalog) Command::DumpCatalog(dump_catalog) => dump_catalog::command(*dump_catalog)
.await .await
.context(DumpCatalogError), .context(DumpCatalogError),
Command::PrintCpu => { Command::PrintCpu => {