about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2015-08-11 17:27:34 +0000
committerbors <bors@rust-lang.org>2015-08-11 17:27:34 +0000
commitdcdcc6f6bcfc418fd828dcdc3f792d9b4edbb658 (patch)
tree7e91d5a760a6d114cd7d8c6d9cc2b384b560522e /src
parent91c618f133a35ffccc7e03e06f9318c59d091ae3 (diff)
parentf0ea2b66f366bd2a4f9442c92552762a355a04c4 (diff)
downloadrust-dcdcc6f6bcfc418fd828dcdc3f792d9b4edbb658.tar.gz
rust-dcdcc6f6bcfc418fd828dcdc3f792d9b4edbb658.zip
Auto merge of #27571 - TimNN:pretty-no-crate-type, r=alexcrichton
Because I wanted to change the pretty test as little as possible I added `// compiler-flags: --crate-type=lib` to those test that failed because of a missing `main`. Passes `make check-stage1-pretty` locally.

cc @nrc
cc #27567
Diffstat (limited to 'src')
-rw-r--r--src/compiletest/runtest.rs1
-rw-r--r--src/test/pretty/blank-lines.rs2
-rw-r--r--src/test/pretty/block-comment-multiple-asterisks.rs2
-rw-r--r--src/test/pretty/block-comment-trailing-whitespace.rs2
-rw-r--r--src/test/pretty/block-comment-trailing-whitespace2.rs2
-rw-r--r--src/test/pretty/block-disambig.rs2
-rw-r--r--src/test/pretty/doc-comments.rs2
-rw-r--r--src/test/pretty/empty-impl.pp5
-rw-r--r--src/test/pretty/empty-impl.rs2
-rw-r--r--src/test/pretty/empty-lines.rs2
-rw-r--r--src/test/pretty/for-comment.rs2
-rw-r--r--src/test/pretty/import-renames.rs2
-rw-r--r--src/test/pretty/unary-op-disambig.rs2
13 files changed, 22 insertions, 6 deletions
diff --git a/src/compiletest/runtest.rs b/src/compiletest/runtest.rs
index 5b62f29b824..5d9c430beaf 100644
--- a/src/compiletest/runtest.rs
+++ b/src/compiletest/runtest.rs
@@ -315,7 +315,6 @@ actual:\n\
         // FIXME (#9639): This needs to handle non-utf8 paths
         let mut args = vec!("-".to_string(),
                             "-Zno-trans".to_string(),
-                            "--crate-type=lib".to_string(),
                             format!("--target={}", target),
                             "-L".to_string(),
                             config.build_base.to_str().unwrap().to_string(),
diff --git a/src/test/pretty/blank-lines.rs b/src/test/pretty/blank-lines.rs
index 4d135801dab..e78f8f5fc9f 100644
--- a/src/test/pretty/blank-lines.rs
+++ b/src/test/pretty/blank-lines.rs
@@ -8,6 +8,8 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// compile-flags: --crate-type=lib
+
 // pp-exact
 fn f() -> [isize; 3] {
     let picard = 0;
diff --git a/src/test/pretty/block-comment-multiple-asterisks.rs b/src/test/pretty/block-comment-multiple-asterisks.rs
index f9f657fa8e2..fbdafef29d8 100644
--- a/src/test/pretty/block-comment-multiple-asterisks.rs
+++ b/src/test/pretty/block-comment-multiple-asterisks.rs
@@ -8,6 +8,8 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// compile-flags: --crate-type=lib
+
 // pp-exact
 /***
 More than two asterisks means that it isn't a doc comment.
diff --git a/src/test/pretty/block-comment-trailing-whitespace.rs b/src/test/pretty/block-comment-trailing-whitespace.rs
index fd4a978a7ad..50f1b035bb2 100644
--- a/src/test/pretty/block-comment-trailing-whitespace.rs
+++ b/src/test/pretty/block-comment-trailing-whitespace.rs
@@ -8,6 +8,8 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// compile-flags: --crate-type=lib
+
 // pp-exact
 fn f() {
     /*
diff --git a/src/test/pretty/block-comment-trailing-whitespace2.rs b/src/test/pretty/block-comment-trailing-whitespace2.rs
index 951799a3528..99c6ca43294 100644
--- a/src/test/pretty/block-comment-trailing-whitespace2.rs
+++ b/src/test/pretty/block-comment-trailing-whitespace2.rs
@@ -8,6 +8,8 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// compile-flags: --crate-type=lib
+
 // pp-exact
 fn f() {
 } /*
diff --git a/src/test/pretty/block-disambig.rs b/src/test/pretty/block-disambig.rs
index 3d5e6e78dea..5f88f903678 100644
--- a/src/test/pretty/block-disambig.rs
+++ b/src/test/pretty/block-disambig.rs
@@ -8,6 +8,8 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// compile-flags: --crate-type=lib
+
 // A bunch of tests for syntactic forms involving blocks that were
 // previously ambiguous (e.g. 'if true { } *val;' gets parsed as a
 // binop)
diff --git a/src/test/pretty/doc-comments.rs b/src/test/pretty/doc-comments.rs
index 02d141f5163..62cadd7cc3e 100644
--- a/src/test/pretty/doc-comments.rs
+++ b/src/test/pretty/doc-comments.rs
@@ -8,6 +8,8 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// compile-flags: --crate-type=lib
+
 // pp-exact
 
 // some single-line non-doc comment
diff --git a/src/test/pretty/empty-impl.pp b/src/test/pretty/empty-impl.pp
deleted file mode 100644
index 685cdcdaead..00000000000
--- a/src/test/pretty/empty-impl.pp
+++ /dev/null
@@ -1,5 +0,0 @@
-trait X { }
-impl X for uint { }
-
-trait Y { }
-impl Y for uint { }
diff --git a/src/test/pretty/empty-impl.rs b/src/test/pretty/empty-impl.rs
index b30f2264355..74445c9432d 100644
--- a/src/test/pretty/empty-impl.rs
+++ b/src/test/pretty/empty-impl.rs
@@ -8,6 +8,8 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// compile-flags: --crate-type=lib
+
 trait X { fn dummy(&self) { } }
 impl X for usize { }
 
diff --git a/src/test/pretty/empty-lines.rs b/src/test/pretty/empty-lines.rs
index 3104941fb46..cc5f5a83a46 100644
--- a/src/test/pretty/empty-lines.rs
+++ b/src/test/pretty/empty-lines.rs
@@ -8,6 +8,8 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// compile-flags: --crate-type=lib
+
 // Issue #759
 // Whitespace under block opening should not expand forever
 
diff --git a/src/test/pretty/for-comment.rs b/src/test/pretty/for-comment.rs
index 43c41deaaea..af76c1d9406 100644
--- a/src/test/pretty/for-comment.rs
+++ b/src/test/pretty/for-comment.rs
@@ -8,6 +8,8 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// compile-flags: --crate-type=lib
+
 // pp-exact
 
 fn f(v: &[isize]) -> isize {
diff --git a/src/test/pretty/import-renames.rs b/src/test/pretty/import-renames.rs
index 47a878711ba..311835eba1b 100644
--- a/src/test/pretty/import-renames.rs
+++ b/src/test/pretty/import-renames.rs
@@ -8,6 +8,8 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// compile-flags: --crate-type=lib
+
 // pp-exact
 
 use std::io::{self, Error as IoError};
diff --git a/src/test/pretty/unary-op-disambig.rs b/src/test/pretty/unary-op-disambig.rs
index 2a9066accd5..133c567a74a 100644
--- a/src/test/pretty/unary-op-disambig.rs
+++ b/src/test/pretty/unary-op-disambig.rs
@@ -8,6 +8,8 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
+// compile-flags: --crate-type=lib
+
 // Preserve semicolons that disambiguate unops
 
 fn f() { }