Test for infix resolve

This commit is contained in:
Andrey Breslav
2011-03-11 13:05:51 +03:00
parent 82261a2c2e
commit 28a88faf61
5 changed files with 36 additions and 2 deletions
@@ -0,0 +1,14 @@
~X~class X<~T~T> {
fun foo(a : `T`T) : `X`X<`T`T>{}
~plus~fun plus(t : `T`T) : Int {}
}
~t~fun <~t.T~T> t(~t.t~t : `t.T`T) : `t.T`T {
`t`t<Int>(1)`:std::Int`
`t`t<`t.T`T>(`t.t`t)`:t.T`
new `X`X<`t.T`T>()
1 `std::Int.plus(Int)`+ 1
new X<String>() `plus`+ "1"
new X<String>() `plus`plus "sadfas"
new X<String>().`plus`plus("")
}