about summary refs log tree commit diff
path: root/src/bin
diff options
context:
space:
mode:
authorAlex Newman <posix4e@gmail.com>2015-08-18 11:04:58 -0700
committerAlex Newman <posix4e@gmail.com>2015-08-18 11:35:18 -0700
commit2f4ef7dd1e78d6d73d5d983ccc97d2fee68b4b7f (patch)
tree7bbc16077df4f7243018828d142f846d5fb3c4c9 /src/bin
parent68627522b0d34ee8712bcfb05edfe7ff157ec035 (diff)
Provide information about default.toml
Diffstat (limited to 'src/bin')
-rw-r--r--src/bin/rustfmt.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/bin/rustfmt.rs b/src/bin/rustfmt.rs
index 3ee7d888af0..a7f65b0bee0 100644
--- a/src/bin/rustfmt.rs
+++ b/src/bin/rustfmt.rs
@@ -19,7 +19,9 @@ use std::io::Read;
 
 fn main() {
     let args: Vec<_> = std::env::args().collect();
-    let mut def_config_file = File::open("default.toml").unwrap();
+    let mut def_config_file = File::open("default.toml").unwrap_or_else(|e| {
+        panic!("Unable to open configuration file [default.toml] {}",e)
+    });
     let mut def_config = String::new();
     def_config_file.read_to_string(&mut def_config).unwrap();