Debian Codegraph @

lang/interpret_test/TestAstFunc1/fail2.txtar

raw
1 -- main.mcl --
2 import "fmt"
3 $x str = if true { # should fail unification
4 42
5 } else {
6 13
7 }
8 test "t1" {
9 anotherstr => fmt.printf("hello %s", $x),
10 }
11 -- OUTPUT --
12 # err: errUnify: type/value inconsistent at arg #1 for func `fmt.printf`: str != int