remove need for taking code_dir

This commit is contained in:
Mark Thom
2018-10-06 16:25:10 -06:00
parent 254ff9715b
commit c85eba0e22
5 changed files with 359 additions and 287 deletions

View File

@@ -46,10 +46,11 @@ pub fn read_toplevel(wam: &mut Machine) -> Result<Input, ParserError> {
},
_ => {
let mut term_stream = TermStream::new(stdin.lock(), wam.indices.atom_tbl.clone(),
wam.machine_flags());
wam.machine_flags(), &mut wam.indices,
&mut wam.policies, &mut wam.code_repo);
term_stream.add_to_top(buffer.as_str());
Ok(Input::Term(term_stream.read_term(wam, &OpDir::new())?))
Ok(Input::Term(term_stream.read_term(&mut wam.machine_st, &OpDir::new())?))
}
}
}