Change type tests

Linux and MacOS produced different results, so the queried types are now limited to ones that are visible in the source code.
This commit is contained in:
Tamas Vajk
2022-05-23 10:38:05 +02:00
parent d3e64f5135
commit 4732793fb6
3 changed files with 27 additions and 2219 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -5,13 +5,10 @@ class Foo {
val propInt: Int = 1
val propLong: Long = 1
/*
TODO
val propUByte: UByte = 1u
val propUShort: UShort = 1u
val propUInt: UInt = 1u
val propULong: ULong = 1u
*/
val propFloat: Float = 1.0f
val propDouble: Double = 1.0
@@ -25,14 +22,22 @@ TODO
val propNullableNothing: Nothing? = null
/*
TODO
val propArray: Array<Int> = arrayOf(1, 2, 3)
val propByteArray: ByteArray = byteArrayOf(1, 2, 3)
val propShortArray: ShortArray = shortArrayOf(1, 2, 3)
val propIntArray: IntArray = intArrayOf(1, 2, 3)
val propLongArray: LongArray = longArrayOf(1, 2, 3)
*/
}
class Gen<T> {
fun fn1(a: T) {
val x: Gen<Gen<Int>> = Gen<Gen<Int>>()
class Local<U> {}
val y: Gen<Local<Int>> = Gen<Local<Int>>()
val z = object { }
}
fun fn2(a: Gen<out String>, b: Gen<in String>, c: Gen<in Nothing>, d: Gen<out Any?>) {
}
}

View File

@@ -1,4 +1,8 @@
import java
from Type t
where
t.fromSource()
or
exists(TypeAccess ta | ta.fromSource() and ta.getType() = t)
select t.toString(), concat(t.getAPrimaryQlClass(), ", ")