3 ms·
It's definitely worth reading the full thread if you haven't > Did you know you can just fork() the @rustlang compiler from your proc_macro? :D > This is, of
by iudqnolq 5y ago
It's definitely worth reading the full thread if you haven't
> Did you know you can just fork() the @rustlang
compiler from your proc_macro? :D
> This is, of course, a horrible idea.
> Unfortunately rustc is multithreaded and fork() only forks one thread. We'll just assume the other threads weren't doing anything important.
> In today's rustc, this means we're only missing the main thread in the fork. But that one was only going to call exit() after joining our thread anyway, so not very important. It just means the process always exits with a success status. So instead we grep the output for "error".
Any my favorite reply:
> Is this a rust implementation of autoconf?
https://mobile.twitter.com/m_ou_se/status/1368632701448818691 https://mobile.twitter.com/m_ou_se/status/136863270144881869...