feat(tvix/eval): track source spans for assert

Change-Id: I5415f63ddde388847a261da4ce9a8d8235657535
Reviewed-on: https://cl.tvl.fyi/c/depot/+/6391
Tested-by: BuildkiteCI
Reviewed-by: sterni <sternenseemann@systemli.org>
This commit is contained in:
Vincent Ambo 2022-09-01 17:26:52 +03:00 committed by tazjin
parent 805c1870ee
commit baa012d5a3

View file

@ -604,7 +604,7 @@ impl Compiler<'_> {
fn compile_assert(&mut self, slot: Option<LocalIdx>, node: ast::Assert) {
// Compile the assertion condition to leave its value on the stack.
self.compile(slot, node.condition().unwrap());
self.push_op_old(OpCode::OpAssert);
self.push_op(OpCode::OpAssert, &node);
// The runtime will abort evaluation at this point if the
// assertion failed, if not the body simply continues on like