about summary refs log tree commit diff
path: root/tvix/eval/src/eval.rs
diff options
context:
space:
mode:
authorVincent Ambo <mail@tazj.in>2022-08-24T17·17+0300
committertazjin <tazjin@tvl.su>2022-09-02T14·13+0000
commitb8f36ba09778145bcc04017ebcb8d4f9a0e9da8a (patch)
tree4ea8ef715091d63f76d2c22a5be2daee1a1deba9 /tvix/eval/src/eval.rs
parent2023b8e33f0e1700ecbaebf4c6fc37a479e73329 (diff)
chore(tvix/eval): print slightly more information about warnings r/4599
This is just for dev comfort, it's not going to be useful for the
final version.

Change-Id: I05fdd590097a61085ed641810655d9ddaf8f3511
Reviewed-on: https://cl.tvl.fyi/c/depot/+/6265
Reviewed-by: sterni <sternenseemann@systemli.org>
Tested-by: BuildkiteCI
Diffstat (limited to 'tvix/eval/src/eval.rs')
-rw-r--r--tvix/eval/src/eval.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/tvix/eval/src/eval.rs b/tvix/eval/src/eval.rs
index 8cb44b87ea08..2f4bd234573b 100644
--- a/tvix/eval/src/eval.rs
+++ b/tvix/eval/src/eval.rs
@@ -36,8 +36,9 @@ pub fn interpret(code: &str, location: Option<PathBuf>) -> EvalResult<Value> {
 
     for warning in result.warnings {
         eprintln!(
-            "warning: {:?} at {:?}",
+            "warning: {:?} at `{:?}`[{:?}]",
             warning.kind,
+            warning.node.text(),
             warning.node.text_range().start()
         )
     }