about summary refs log tree commit diff
path: root/src/bin
diff options
context:
space:
mode:
authorAaron Lobb <alobb@hmc.edu>2015-09-14 13:43:55 -0700
committerAaron Lobb <alobb@hmc.edu>2015-09-14 13:43:55 -0700
commitd773580715ae3f4dd7ea1a4561b25f0b29f47bf8 (patch)
tree0bb023e93313e53b07a8de6ef9ffa37d02a1d202 /src/bin
parentcd9e9b5db08f03dff80e91cbc7e6beaf441cf3ec (diff)
Changed ConfigType trait to only return a string of variants, rather than a vec
Diffstat (limited to 'src/bin')
-rw-r--r--src/bin/rustfmt.rs10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/bin/rustfmt.rs b/src/bin/rustfmt.rs
index ee023c9eca8..2bc6e255ac0 100644
--- a/src/bin/rustfmt.rs
+++ b/src/bin/rustfmt.rs
@@ -17,7 +17,7 @@ extern crate rustfmt;
 extern crate toml;
 
 use rustfmt::{WriteMode, run};
-use rustfmt::config::{Config, ConfigHelpVariantTypes};
+use rustfmt::config::Config;
 
 use std::env;
 use std::fs::{File, PathExt};
@@ -87,13 +87,7 @@ fn print_usage<S: Into<String>>(reason: S) {
              reason.into());
 
     for option in Config::get_docs() {
-        let variants = option.variant_names();
-        let variant_names: String = match *variants {
-            ConfigHelpVariantTypes::UsizeConfig => "<unsigned integer>".into(),
-            ConfigHelpVariantTypes::BoolConfig => "<boolean>".into(),
-            ConfigHelpVariantTypes::EnumConfig(ref variants) => variants.join(", "),
-        };
-        println!("{}, {}, Possible values: {}", option.option_name(), option.doc_string(), variant_names);
+        println!("{}, {}, Possible values: {}", option.option_name(), option.doc_string(), option.variant_names());
     }
 }