Skip to content

Commit 6e99017

Browse files
committed
Remove codegen_channel query from compiler interface
1 parent 4e0c0aa commit 6e99017

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

c2rust-refactor/src/command.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,6 @@ impl RefactorState {
325325

326326
// Ensure that we've dropped any copies of the session Lrc
327327
let _ = self.compiler.lower_to_hir()?.take();
328-
let _ = self.compiler.codegen_channel()?.take();
329328

330329
r
331330
}

c2rust-refactor/src/driver.rs

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@ use std::collections::HashSet;
2626
use std::mem;
2727
use std::path::{Path, PathBuf};
2828
use std::rc::Rc;
29-
use std::sync::mpsc;
3029
use std::sync::Arc;
3130
use syntax::ast;
3231
use syntax::ast::DUMMY_NODE_ID;
@@ -337,8 +336,6 @@ struct Queries {
337336
dep_graph: Query<DepGraph>,
338337
lower_to_hir: Query<(Steal<hir_map::Forest>, ExpansionResult)>,
339338
prepare_outputs: Query<OutputFilenames>,
340-
codegen_channel: Query<(Steal<mpsc::Sender<Box<dyn Any + Send>>>,
341-
Steal<mpsc::Receiver<Box<dyn Any + Send>>>)>,
342339
global_ctxt: Query<BoxedGlobalCtxt>,
343340
ongoing_codegen: Query<Box<dyn Any>>,
344341
link: Query<()>,
@@ -600,7 +597,7 @@ pub fn parse_impl_items(sess: &Session, src: &str) -> Vec<ImplItem> {
600597
// workaround that may cause suboptimal error messages.
601598
let mut p = make_parser(sess, &format!("impl ! {{ {} }}", src));
602599
match p.parse_item() {
603-
Ok(item) => match item.expect("expected to find an item").into_inner().node {
600+
Ok(item) => match item.expect("expected to find an item").into_inner().kind {
604601
ItemKind::Impl(_, _, _, _, _, _, items) => items,
605602
_ => panic!("expected to find an impl item"),
606603
},
@@ -614,7 +611,7 @@ pub fn parse_foreign_items(sess: &Session, src: &str) -> Vec<ForeignItem> {
614611
// workaround that may cause suboptimal error messages.
615612
let mut p = make_parser(sess, &format!("extern {{ {} }}", src));
616613
match p.parse_item() {
617-
Ok(item) => match item.expect("expected to find an item").into_inner().node {
614+
Ok(item) => match item.expect("expected to find an item").into_inner().kind {
618615
ItemKind::ForeignMod(fm) => fm.items,
619616
_ => panic!("expected to find a foreignmod item"),
620617
},

0 commit comments

Comments
 (0)