A couple of tests for default libraries.

This commit is contained in:
Alexander Gorshenev
2017-09-19 16:19:22 +03:00
committed by alexander-gorshenev
parent 27f7e4263b
commit f1c3e866b4
4 changed files with 23 additions and 0 deletions
+11
View File
@@ -1220,6 +1220,17 @@ task link(type: LinkKonanTest) {
}
*/
task link_omit_unused(type: LinkKonanTest) {
goldValue = "Hello\n"
source = "link/omit/hello.kt"
lib = "link/omit/lib.kt"
}
task link_default_libs(type: RunKonanTest) {
goldValue = "ptrdiff = 0\n"
source = "link/default/default.kt"
}
task for0(type: RunKonanTest) {
goldValue = "2\n3\n4\n"
source = "runtime/basic/for0.kt"
@@ -0,0 +1,7 @@
import posix.*
fun main(args: Array<String>) {
// Just check the typealias is in scope.
val ptrdiff: ptrdiff_t = 0L
println("ptrdiff = $ptrdiff")
}
+3
View File
@@ -0,0 +1,3 @@
fun main(args: Array<String>) {
println("Hello")
}
+2
View File
@@ -0,0 +1,2 @@
package foo
fun foo() {}