Skip to content

Commit

Permalink
Remove no_dead_strip marks for class refs & sels
Browse files Browse the repository at this point in the history
  • Loading branch information
Berrysoft committed Nov 16, 2024
1 parent 4ea22f2 commit 2e98c41
Show file tree
Hide file tree
Showing 23 changed files with 110 additions and 110 deletions.
8 changes: 4 additions & 4 deletions crates/objc2/src/macros/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -442,11 +442,11 @@ macro_rules! __statics_sel {
// Clang uses `no_dead_strip` in the link section for some reason,
// which other tools (notably some LLVM tools) now assume is
// present, so we have to add it as well.
link_section = "__DATA,__objc_selrefs,literal_pointers,no_dead_strip",
link_section = "__DATA,__objc_selrefs,literal_pointers",
)]
#[cfg_attr(
all(target_os = "macos", target_arch = "x86"),
link_section = "__OBJC,__message_refs,literal_pointers,no_dead_strip",
link_section = "__OBJC,__message_refs,literal_pointers",
)]
#[export_name = $crate::__macro_helpers::concat!("\x01L_OBJC_SELECTOR_REFERENCES_", $hash)]
static REF: $crate::__macro_helpers::SyncUnsafeCell<$crate::runtime::Sel> = unsafe {
Expand Down Expand Up @@ -504,7 +504,7 @@ macro_rules! __statics_class {
}

/// SAFETY: Same as `REF` above in `__statics_sel!`.
#[link_section = "__DATA,__objc_classrefs,regular,no_dead_strip"]
#[link_section = "__DATA,__objc_classrefs,regular"]
#[export_name = $crate::__macro_helpers::concat!(
"\x01L_OBJC_CLASSLIST_REFERENCES_$_",
$hash,
Expand Down Expand Up @@ -536,7 +536,7 @@ macro_rules! __statics_class {
static NAME_DATA: [$crate::__macro_helpers::u8; X.len()] = $crate::__statics_string_to_known_length_bytes!(X);

/// SAFETY: Same as `REF` above in `__statics_sel!`.
#[link_section = "__OBJC,__cls_refs,literal_pointers,no_dead_strip"]
#[link_section = "__OBJC,__cls_refs,literal_pointers"]
#[export_name = $crate::__macro_helpers::concat!(
"\x01L_OBJC_CLASS_REFERENCES_",
$hash,
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 2e98c41

Please sign in to comment.