Skip to content

Commit 2f636a3

Browse files
Future possibilities: Expand to suggest #[export] annotations.
1 parent 90126c7 commit 2f636a3

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

text/0000-export-executable-symbols.md

+6
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,12 @@ Most people don't really notice it, for good or for ill.
101101
# Future possibilities
102102
[future-possibilities]: #future-possibilities
103103

104+
We could introduce a new source annotation, `#[export]`. For backwards
105+
compatibility with current behavior, `#[no_mangle]` symbols could be exported
106+
by default - and possibly disabled with `#[export(false)]`. This would
107+
reduce the need to hide this change to compiler/linker behavior behind a
108+
compiler flag or crate annotation.
109+
104110
Maybe other options to control what symbols get exported? Although I'd fear
105111
turning rustc into yet another linker script implementation, so maybe not.
106112

0 commit comments

Comments
 (0)