]> git.lizzy.rs Git - rust.git/commitdiff
Rollup merge of #107595 - michaelwoerister:retry_proc_macro_loading, r=petrochenkov
authorMichael Goulet <michael@errs.io>
Fri, 3 Feb 2023 22:15:22 +0000 (14:15 -0800)
committerGitHub <noreply@github.com>
Fri, 3 Feb 2023 22:15:22 +0000 (14:15 -0800)
Retry opening proc-macro DLLs a few times on Windows.

On Windows, the compiler [sometimes](https://users.rust-lang.org/t/error-loadlibraryexw-failed/77603) fails with the message `error: LoadLibraryExW failed` when trying to load a proc-macro crate. The error seems to occur intermittently, similar to https://github.com/rust-lang/rust/issues/86929, however, it seems to be almost impossible to reproduce outside of CI environments and thus very hard to debug. The fact that the error only occurs intermittently makes me think that this is a timing related issue.

This PR is an attempt to mitigate the issue by letting the compiler retry a few times when encountering this specific error (which resolved the issue described in https://github.com/rust-lang/rust/issues/86929).


Trivial merge