genpolicy tweaks (#141)

Allow `import input` instead of erroring out.
This import is redundant and has no effect.

Emit `print` messages to stderr onstead of stdout.

Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
This commit is contained in:
Anand Krishnamoorthi
2024-02-11 16:52:12 -08:00
committed by GitHub
parent 3b2e639918
commit 13eb06e4be
3 changed files with 21 additions and 2 deletions

View File

@@ -35,7 +35,7 @@ fn print(span: &Span, _params: &[Ref<Expr>], args: &[Value], _strict: bool) -> R
}
if !msg.is_empty() {
println!("{}", &msg[1..]);
eprintln!("{}", &msg[1..]);
}
Ok(Value::Bool(true))
}