Skip to content

Commit

Permalink
use get() directly on the terms HashMap because we don't care that th…
Browse files Browse the repository at this point in the history
…e term hasn't had it's imports resolved (#1522)
  • Loading branch information
Radvendii authored Aug 10, 2023
1 parent 07be729 commit 701b7ed
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions core/src/program.rs
Original file line number Diff line number Diff line change
Expand Up @@ -175,8 +175,11 @@ impl<EC: EvalCache> Program<EC> {
Ok(self
.vm
.import_resolver()
.get(self.main_id)
.expect("File parsed and then immediately accessed doesn't exist"))
.terms()
.get(&self.main_id)
.expect("File parsed and then immediately accessed doesn't exist")
.term
.clone())
}

/// Retrieve the parsed term and typecheck it, and generate a fresh initial environment. Return
Expand Down

0 comments on commit 701b7ed

Please sign in to comment.