about summary refs log tree commit diff
diff options
context:
space:
mode:
authorJeffrey Seyfried <jeffrey.seyfried@gmail.com>2016-11-18 00:51:24 +0000
committerJeffrey Seyfried <jeffrey.seyfried@gmail.com>2016-11-18 01:13:10 +0000
commit8918ddf0ed7ed02546919b2a360543c0930d6486 (patch)
treebc7ef302b00bc646be8f98abfe91c99cdce6a633
parent04886f2c983cc06f595578e3d35b92fd44400210 (diff)
downloadrust-8918ddf0ed7ed02546919b2a360543c0930d6486.tar.gz
rust-8918ddf0ed7ed02546919b2a360543c0930d6486.zip
Add regression test.
-rw-r--r--src/test/run-make/issue-37839/Makefile6
-rw-r--r--src/test/run-make/issue-37839/a.rs13
-rw-r--r--src/test/run-make/issue-37839/b.rs12
-rw-r--r--src/test/run-make/issue-37839/c.rs12
4 files changed, 43 insertions, 0 deletions
diff --git a/src/test/run-make/issue-37839/Makefile b/src/test/run-make/issue-37839/Makefile
new file mode 100644
index 00000000000..f17ce537fb8
--- /dev/null
+++ b/src/test/run-make/issue-37839/Makefile
@@ -0,0 +1,6 @@
+-include ../tools.mk
+
+all:
+	$(RUSTC) a.rs && $(RUSTC) b.rs
+	$(BARE_RUSTC) c.rs -L dependency=$(TMPDIR) --extern b=$(TMPDIR)/libb.rlib \
+		--out-dir=$(TMPDIR)
diff --git a/src/test/run-make/issue-37839/a.rs b/src/test/run-make/issue-37839/a.rs
new file mode 100644
index 00000000000..3dff45388c7
--- /dev/null
+++ b/src/test/run-make/issue-37839/a.rs
@@ -0,0 +1,13 @@
+// Copyright 2016 The Rust Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution and at
+// http://rust-lang.org/COPYRIGHT.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+#![feature(proc_macro)]
+#![allow(unused)]
+#![crate_type = "proc-macro"]
diff --git a/src/test/run-make/issue-37839/b.rs b/src/test/run-make/issue-37839/b.rs
new file mode 100644
index 00000000000..82f48f6d8d6
--- /dev/null
+++ b/src/test/run-make/issue-37839/b.rs
@@ -0,0 +1,12 @@
+// Copyright 2016 The Rust Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution and at
+// http://rust-lang.org/COPYRIGHT.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+#![crate_type = "lib"]
+#[macro_use] extern crate a;
diff --git a/src/test/run-make/issue-37839/c.rs b/src/test/run-make/issue-37839/c.rs
new file mode 100644
index 00000000000..85bece51427
--- /dev/null
+++ b/src/test/run-make/issue-37839/c.rs
@@ -0,0 +1,12 @@
+// Copyright 2016 The Rust Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution and at
+// http://rust-lang.org/COPYRIGHT.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+#![crate_type = "lib"]
+extern crate b;