diff options
Diffstat (limited to 'tests/template/t19700.nim')
-rw-r--r-- | tests/template/t19700.nim | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/template/t19700.nim b/tests/template/t19700.nim new file mode 100644 index 000000000..cc2944944 --- /dev/null +++ b/tests/template/t19700.nim @@ -0,0 +1,10 @@ +discard """ + errormsg: "type mismatch: got <Obj, Obj, template (x: untyped, y: untyped): untyped>" +""" + +type Obj = object + +proc apply[T, R](a, b: T; f: proc(x, y: T): R): R = f(a, b) + +let a, b = Obj() +discard apply(a, b, `!=`) |