about summary refs log tree commit diff
path: root/src/comp
diff options
context:
space:
mode:
authorGraydon Hoare <graydon@mozilla.com>2011-05-26 15:22:08 +0000
committerGraydon Hoare <graydon@mozilla.com>2011-05-26 15:22:08 +0000
commit9491dc3e61b114eda06a61bbec76742237017f49 (patch)
tree7a051d4a589dbee9aaf86af069f85a4760e4f85e /src/comp
parentdc1b34288c1618aaa7d7f012cb3ec2e403336b01 (diff)
Add early returns to rustc main on non-compiling paths.
Diffstat (limited to 'src/comp')
-rw-r--r--src/comp/driver/rustc.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/comp/driver/rustc.rs b/src/comp/driver/rustc.rs
index 7dcf41b00e5..ee77330186c 100644
--- a/src/comp/driver/rustc.rs
+++ b/src/comp/driver/rustc.rs
@@ -373,8 +373,10 @@ fn main(vec[str] args) {
     auto ls = opt_present(match, "ls");
     if (pretty || typed_pretty) {
         pretty_print_input(sess, env, ifile, typed_pretty);
+        ret;
     } else if (ls) {
         front::creader::list_file_metadata(ifile, std::io::stdout());
+        ret;
     } else {
         alt (output_file) {
             case (none[str]) {