From 631cd5845e8de329d0e227aaa707d7ea228b8f8f Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:20:29 +0200 Subject: Merging upstream version 1.70.0+dfsg1. Signed-off-by: Daniel Baumann --- .../share-generics-dylib/Makefile | 22 ---------------------- .../share-generics-dylib/instance_provider_a.rs | 6 ------ .../share-generics-dylib/instance_provider_b.rs | 6 ------ .../share-generics-dylib/instance_user_a_rlib.rs | 9 --------- .../share-generics-dylib/instance_user_b_rlib.rs | 9 --------- .../share-generics-dylib/instance_user_dylib.rs | 7 ------- .../share-generics-dylib/linked_leaf.rs | 15 --------------- 7 files changed, 74 deletions(-) delete mode 100644 tests/run-make-fulldeps/share-generics-dylib/Makefile delete mode 100644 tests/run-make-fulldeps/share-generics-dylib/instance_provider_a.rs delete mode 100644 tests/run-make-fulldeps/share-generics-dylib/instance_provider_b.rs delete mode 100644 tests/run-make-fulldeps/share-generics-dylib/instance_user_a_rlib.rs delete mode 100644 tests/run-make-fulldeps/share-generics-dylib/instance_user_b_rlib.rs delete mode 100644 tests/run-make-fulldeps/share-generics-dylib/instance_user_dylib.rs delete mode 100644 tests/run-make-fulldeps/share-generics-dylib/linked_leaf.rs (limited to 'tests/run-make-fulldeps/share-generics-dylib') diff --git a/tests/run-make-fulldeps/share-generics-dylib/Makefile b/tests/run-make-fulldeps/share-generics-dylib/Makefile deleted file mode 100644 index 065fb574c..000000000 --- a/tests/run-make-fulldeps/share-generics-dylib/Makefile +++ /dev/null @@ -1,22 +0,0 @@ -# This test makes sure all generic instances get re-exported from Rust dylibs for use by -# `-Zshare-generics`. There are two rlibs (`instance_provider_a` and `instance_provider_b`) -# which both provide an instance of `Cell::set`. There is `instance_user_dylib` which is -# supposed to re-export both these instances, and then there are `instance_user_a_rlib` and -# `instance_user_b_rlib` which each rely on a specific instance to be available. -# -# In the end everything is linked together into `linked_leaf`. If `instance_user_dylib` does -# not export both then we'll get an `undefined reference` error for one of the instances. -# -# This is regression test for https://github.com/rust-lang/rust/issues/67276. - -include ../../run-make-fulldeps/tools.mk - -COMMON_ARGS=-Cprefer-dynamic -Zshare-generics=yes -Ccodegen-units=1 -Csymbol-mangling-version=v0 - -all: - $(RUSTC) instance_provider_a.rs $(COMMON_ARGS) --crate-type=rlib - $(RUSTC) instance_provider_b.rs $(COMMON_ARGS) --crate-type=rlib - $(RUSTC) instance_user_dylib.rs $(COMMON_ARGS) --crate-type=dylib - $(RUSTC) instance_user_a_rlib.rs $(COMMON_ARGS) --crate-type=rlib - $(RUSTC) instance_user_b_rlib.rs $(COMMON_ARGS) --crate-type=rlib - $(RUSTC) linked_leaf.rs $(COMMON_ARGS) --crate-type=bin diff --git a/tests/run-make-fulldeps/share-generics-dylib/instance_provider_a.rs b/tests/run-make-fulldeps/share-generics-dylib/instance_provider_a.rs deleted file mode 100644 index b4e125ac0..000000000 --- a/tests/run-make-fulldeps/share-generics-dylib/instance_provider_a.rs +++ /dev/null @@ -1,6 +0,0 @@ -use std::cell::Cell; - -pub fn foo() { - let a: Cell = Cell::new(1); - a.set(123); -} diff --git a/tests/run-make-fulldeps/share-generics-dylib/instance_provider_b.rs b/tests/run-make-fulldeps/share-generics-dylib/instance_provider_b.rs deleted file mode 100644 index f613db873..000000000 --- a/tests/run-make-fulldeps/share-generics-dylib/instance_provider_b.rs +++ /dev/null @@ -1,6 +0,0 @@ -use std::cell::Cell; - -pub fn foo() { - let b: Cell = Cell::new(1); - b.set(123); -} diff --git a/tests/run-make-fulldeps/share-generics-dylib/instance_user_a_rlib.rs b/tests/run-make-fulldeps/share-generics-dylib/instance_user_a_rlib.rs deleted file mode 100644 index c8e6ab95c..000000000 --- a/tests/run-make-fulldeps/share-generics-dylib/instance_user_a_rlib.rs +++ /dev/null @@ -1,9 +0,0 @@ -extern crate instance_provider_a as upstream; -use std::cell::Cell; - -pub fn foo() { - upstream::foo(); - - let b: Cell = Cell::new(1); - b.set(123); -} diff --git a/tests/run-make-fulldeps/share-generics-dylib/instance_user_b_rlib.rs b/tests/run-make-fulldeps/share-generics-dylib/instance_user_b_rlib.rs deleted file mode 100644 index 7c34af6d0..000000000 --- a/tests/run-make-fulldeps/share-generics-dylib/instance_user_b_rlib.rs +++ /dev/null @@ -1,9 +0,0 @@ -extern crate instance_provider_b as upstream; -use std::cell::Cell; - -pub fn foo() { - upstream::foo(); - - let b: Cell = Cell::new(1); - b.set(123); -} diff --git a/tests/run-make-fulldeps/share-generics-dylib/instance_user_dylib.rs b/tests/run-make-fulldeps/share-generics-dylib/instance_user_dylib.rs deleted file mode 100644 index 7c8368eec..000000000 --- a/tests/run-make-fulldeps/share-generics-dylib/instance_user_dylib.rs +++ /dev/null @@ -1,7 +0,0 @@ -extern crate instance_provider_a; -extern crate instance_provider_b; - -pub fn foo() { - instance_provider_a::foo(); - instance_provider_b::foo(); -} diff --git a/tests/run-make-fulldeps/share-generics-dylib/linked_leaf.rs b/tests/run-make-fulldeps/share-generics-dylib/linked_leaf.rs deleted file mode 100644 index e510dad69..000000000 --- a/tests/run-make-fulldeps/share-generics-dylib/linked_leaf.rs +++ /dev/null @@ -1,15 +0,0 @@ -extern crate instance_user_dylib; -extern crate instance_user_a_rlib; -extern crate instance_user_b_rlib; - -use std::cell::Cell; - -fn main() { - - instance_user_a_rlib::foo(); - instance_user_b_rlib::foo(); - instance_user_dylib::foo(); - - let a: Cell = Cell::new(1); - a.set(123); -} -- cgit v1.2.3