Better testing framework, examples added as tests

This commit is contained in:
Andrey Breslav
2011-01-02 21:25:40 +03:00
parent b80460746a
commit 4d4e9cc342
79 changed files with 14379 additions and 60 deletions
@@ -0,0 +1,13 @@
/**
These declarations are "shallow" in the sense that they are not really compiled, only the type-checker uses them
*/
virtual class ReadOnlyArray<out T> : ISized {
[operator] fun get(index : Int) : T
}
virtual class WriteOnlyArray<in T> : ISized { // This is needed to keep IIterator's <T> covariant
[operator] fun set(index : Int, value : T)
}
class MutableArray<T> : ReadOnlyArray<T>, WriteOnlyArray<T> {/*...*/}