Stream: t-compiler

Topic: visit body of function from external crate


Nora (Nov 01 2018 at 23:09, on Zulip):

I want to check if there is an unsafe block in the body of a function from an external crate. I have the DefId of the function.
If the function is local, then I can get the NodeId and the body and visit it. I can get it from the MIR source_scope_local_data. But neither of these work if the function is not local.
How can I do it?

Last update: Nov 16 2019 at 01:00UTC