diff options
| author | bors <bors@rust-lang.org> | 2022-01-20 20:44:14 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2022-01-20 20:44:14 +0000 |
| commit | 777bb86bcdbc568be7cff6eeeaaf81a89b4aa50b (patch) | |
| tree | 82f458e6da62ec8cd4baa7cf5c1b4c2eed5f3cc5 /library/std/src/sys/unix/weak.rs | |
| parent | 74fbbefea8d13683cca5eee62e4740706cb3144a (diff) | |
| parent | dbc97490bbca00e6913c34b8864791d660c60312 (diff) | |
| download | rust-777bb86bcdbc568be7cff6eeeaaf81a89b4aa50b.tar.gz rust-777bb86bcdbc568be7cff6eeeaaf81a89b4aa50b.zip | |
Auto merge of #93119 - matthiaskrgr:rollup-ku3cn5j, r=matthiaskrgr
Rollup of 13 pull requests Successful merges: - #89747 (Add MaybeUninit::(slice_)as_bytes(_mut)) - #89764 (Fix variant index / discriminant confusion in uninhabited enum branching) - #91606 (Stabilize `-Z print-link-args` as `--print link-args`) - #91694 (rustdoc: decouple stability and const-stability) - #92183 (Point at correct argument when async fn output type lifetime disagrees with signature) - #92582 (improve `_` constants in item signature handling) - #92680 (intra-doc: Use the impl's assoc item where possible) - #92704 (Change lint message to be stronger for &T -> &mut T transmute) - #92861 (Rustdoc mobile: put out-of-band info on its own line) - #92992 (Help optimize out backtraces when disabled) - #93038 (Fix star handling in block doc comments) - #93108 (:arrow_up: rust-analyzer) - #93112 (Fix CVE-2022-21658) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'library/std/src/sys/unix/weak.rs')
| -rw-r--r-- | library/std/src/sys/unix/weak.rs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/library/std/src/sys/unix/weak.rs b/library/std/src/sys/unix/weak.rs index 55719b87c7e..da63c068384 100644 --- a/library/std/src/sys/unix/weak.rs +++ b/library/std/src/sys/unix/weak.rs @@ -73,12 +73,14 @@ impl<F> ExternWeak<F> { pub(crate) macro dlsym { (fn $name:ident($($t:ty),*) -> $ret:ty) => ( + dlsym!(fn $name($($t),*) -> $ret, stringify!($name)); + ), + (fn $name:ident($($t:ty),*) -> $ret:ty, $sym:expr) => ( static DLSYM: DlsymWeak<unsafe extern "C" fn($($t),*) -> $ret> = - DlsymWeak::new(concat!(stringify!($name), '\0')); + DlsymWeak::new(concat!($sym, '\0')); let $name = &DLSYM; ) } - pub(crate) struct DlsymWeak<F> { name: &'static str, addr: AtomicUsize, |
