Bug 1405105 - remove Rust init hack now that we require 1.19; r=ccorcoran

We added this to avoid race conditions, but a fix which removes the need
for it has been landed in Rust 1.19+, which we now require.
This commit is contained in:
Nathan Froyd 2017-10-04 09:53:20 -04:00
Родитель dcc75d78ac
Коммит ac2f2367a9
2 изменённых файлов: 0 добавлений и 17 удалений

Просмотреть файл

@ -30,14 +30,6 @@ use std::panic;
// This workaround is fixed in Rust 1.19. For details, see bug 1358151.
thread_local!(static UNUSED_THREAD_LOCAL: () = ());
#[no_mangle]
pub extern "C" fn rust_init_please_remove_this_after_updating_rust_1_19() {
UNUSED_THREAD_LOCAL.with(|_| ());
}
/// Used to implement `nsIDebug2::RustPanic` for testing purposes.
#[no_mangle]
pub extern "C" fn intentional_panic(message: *const c_char) {

Просмотреть файл

@ -231,12 +231,6 @@
extern uint32_t gRestartMode;
extern void InstallSignalHandlers(const char *ProgramName);
// This workaround is fixed in Rust 1.19. For details, see bug 1358151.
// Implementation in toolkit/library/rust/shared/lib.rs
extern "C" {
void rust_init_please_remove_this_after_updating_rust_1_19();
}
#define FILE_COMPATIBILITY_INFO NS_LITERAL_CSTRING("compatibility.ini")
#define FILE_INVALIDATE_CACHES NS_LITERAL_CSTRING(".purgecaches")
@ -3200,9 +3194,6 @@ XREMain::XRE_mainInit(bool* aExitFlag)
return 1;
*aExitFlag = false;
// This workaround is fixed in Rust 1.19. For details, see bug 1358151.
rust_init_please_remove_this_after_updating_rust_1_19();
atexit(UnexpectedExit);
auto expectedShutdown = mozilla::MakeScopeExit([&] {
MozExpectedExit();