INNER CODE UNIT · Rust

after_analysis

willcrichton/flowistry · crates/flowistry_ifc/src/lib.rs:86

  fn after_analysis(
    &mut self,
    _compiler: &rustc_interface::interface::Compiler,
    tcx: TyCtxt,
  ) -> rustc_driver::Compilation {
    let mut visitor = IfcVisitor {
      tcx,
      issue_found: IssueFound::No,
    };
    tcx.hir_visit_all_item_likes_in_crate(&mut visitor);

    if let IssueFound::No = visitor.issue_found {
      let mut stdout = StandardStream::stderr(ColorChoice::Auto);
      let mut green_spec = ColorSpec::new();
      green_spec.set_fg(Some(Color::Green));
      stdout.set_color(&green_spec).unwrap();
      writeln!(stdout, "No security issues found!",).unwrap();
    }

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…