about summary refs log tree commit diff
path: root/tvix/eval/src/compiler
diff options
context:
space:
mode:
authorVincent Ambo <mail@tazj.in>2023-03-06T14·23+0300
committertazjin <tazjin@tvl.su>2023-03-13T20·30+0000
commit5d9bfd7735373cde72ebac4be4a05f1c846c13ba (patch)
tree1420e8d149454eca61c7cba7970fdb7e524854a9 /tvix/eval/src/compiler
parent43b0416bd8b5c4c7c99b146f8cee7b1a979a7782 (diff)
fix(tvix/eval): emit warnings from builtins.import again r/5983
Wires up generator logic to emit warnings that already have spans
attached again.

Change-Id: I9f878cec3b9d4f6f7819e7c71bab7ae70bd3f08b
Reviewed-on: https://cl.tvl.fyi/c/depot/+/8224
Tested-by: BuildkiteCI
Reviewed-by: raitobezarius <tvl@lahfa.xyz>
Diffstat (limited to 'tvix/eval/src/compiler')
-rw-r--r--tvix/eval/src/compiler/import.rs7
1 files changed, 3 insertions, 4 deletions
diff --git a/tvix/eval/src/compiler/import.rs b/tvix/eval/src/compiler/import.rs
index 467fc256afc6..7e1aabbf1f8b 100644
--- a/tvix/eval/src/compiler/import.rs
+++ b/tvix/eval/src/compiler/import.rs
@@ -77,10 +77,9 @@ async fn import_impl(
         });
     }
 
-    // TODO: emit not just the warning kind, hmm
-    // for warning in result.warnings {
-    //     vm.push_warning(warning);
-    // }
+    for warning in result.warnings {
+        generators::emit_warning(&co, warning).await;
+    }
 
     // Compilation succeeded, we can construct a thunk from whatever it spat
     // out and return that.