summaryrefslogtreecommitdiff
path: root/crates/typst-ide
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2024-03-12 11:28:15 +0100
committerGitHub <noreply@github.com>2024-03-12 10:28:15 +0000
commit633c32a55228765adcad41d22d016146e5149db9 (patch)
tree8c1342e7de06e1d3ebdf760d523c954aca7720ef /crates/typst-ide
parentd01ccffad6470ad49d4e47b5c0884dfd23305961 (diff)
Track context (#3623)
Diffstat (limited to 'crates/typst-ide')
-rw-r--r--crates/typst-ide/src/analyze.rs8
1 files changed, 6 insertions, 2 deletions
diff --git a/crates/typst-ide/src/analyze.rs b/crates/typst-ide/src/analyze.rs
index 1fef1b49..9d67b322 100644
--- a/crates/typst-ide/src/analyze.rs
+++ b/crates/typst-ide/src/analyze.rs
@@ -67,8 +67,12 @@ pub fn analyze_import(world: &dyn World, source: &LinkedNode) -> Option<Value> {
};
let context = Context::none();
- let mut vm =
- Vm::new(engine, &context, Scopes::new(Some(world.library())), Span::detached());
+ let mut vm = Vm::new(
+ engine,
+ context.track(),
+ Scopes::new(Some(world.library())),
+ Span::detached(),
+ );
typst::eval::import(&mut vm, source, Span::detached(), true)
.ok()
.map(Value::Module)