Uast: forcing kotlin.uast.force.uinjectionhost=true always

This commit is contained in:
Nicolay Mitropolsky
2020-02-12 16:00:35 +03:00
parent ee48580e06
commit e4b7c39110
42 changed files with 254 additions and 132 deletions
+1 -1
View File
@@ -183,7 +183,7 @@
<registryKey key="kotlin.uast.force.uinjectionhost"
description="Whether to convert `KtStringTemplateExpression` to `KotlinStringTemplateUPolyadicExpression` in all cases"
defaultValue="false"
defaultValue="true"
restartRequired="false"/>
<registryKey key="kotlin.jps.instrument.bytecode"
@@ -301,7 +301,7 @@ internal object KotlinConverter {
}
}
var forceUInjectionHost = Registry.`is`("kotlin.uast.force.uinjectionhost", false)
var forceUInjectionHost = Registry.`is`("kotlin.uast.force.uinjectionhost", true)
@TestOnly
set(value) {
field = value
@@ -19,7 +19,9 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='constructor_call'), argCount = 2))
UIdentifier (Identifier (Annotation))
USimpleNameReferenceExpression (identifier = <init>, resolvesTo = Annotation)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "sv1")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "sv2")
UMethod (name = B2)
UClass (name = AnnotationArray)
@@ -33,7 +35,9 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='array_initializer'), argCount = 2))
UIdentifier (Identifier (arrayOf))
USimpleNameReferenceExpression (identifier = arrayOf, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "sar1")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "sar2")
UMethod (name = C)
UClass (name = C2)
@@ -44,6 +48,8 @@ UFile (package = )
USimpleNameReferenceExpression (identifier = <init>, resolvesTo = Annotation)
UCallExpression (kind = UastCallKind(name='array_initializer'), argCount = 2))
UIdentifier (Identifier ([))
UPolyadicExpression (operator = +)
ULiteralExpression (value = "[sar]1")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "[sar]2")
UMethod (name = C2)
@@ -17,6 +17,7 @@ UFile (package = )
UAnnotation (fqName = WithDefaultValue)
UAnnotation (fqName = SuppressLint)
UNamedExpression (name = value)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "Lorem")
UBlockExpression
UReturnExpression
@@ -30,8 +31,11 @@ UFile (package = )
UAnnotation (fqName = SuppressLint)
UNamedExpression (name = value)
UCallExpression (kind = UastCallKind(name='array_initializer'), argCount = 3))
UPolyadicExpression (operator = +)
ULiteralExpression (value = "Lorem")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "Ipsum")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "Dolor")
UBlockExpression
UReturnExpression
@@ -52,8 +56,11 @@ UFile (package = )
UNamedExpression (name = strs)
UCallExpression (kind = UastCallKind(name='array_initializer'), argCount = 3))
UIdentifier (Identifier ([))
UPolyadicExpression (operator = +)
ULiteralExpression (value = "a")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "b")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "c")
UBlockExpression
UReturnExpression
+1
View File
@@ -4,6 +4,7 @@ UFile (package = ) [public final class AssertionKt {...]
UBlockExpression [{...}] = Nothing
UDeclarationsExpression [var s: java.lang.String = "Not Null"] = Undetermined
ULocalVariable (name = s) [var s: java.lang.String = "Not Null"]
UPolyadicExpression (operator = +) ["Not Null"] = "Not Null"
ULiteralExpression (value = "Not Null") ["Not Null"] = "Not Null"
UReturnExpression [return s!!] = Nothing
UPostfixExpression (operator = !!) [s!!] = (var s = "Not Null")
+4 -4
View File
@@ -21,7 +21,7 @@
[1]:[UTypeReferenceExpression (name = MyAnnotation)]
[1]:[USimpleNameReferenceExpression (identifier = MyAnnotation)]
[1]:[UIdentifier (Identifier (MyAnnotation))]
[1]:[ULiteralExpression (value = "class")]
[1]:[UPolyadicExpression (operator = +)]
[1]:[ULiteralExpression (value = "class")]
[1]:[UIdentifier (Identifier (B))]
[1]:[UExpressionList (class_body)]
@@ -31,7 +31,7 @@
[1]:[UTypeReferenceExpression (name = MyAnnotation)]
[1]:[USimpleNameReferenceExpression (identifier = MyAnnotation)]
[1]:[UIdentifier (Identifier (MyAnnotation))]
[1]:[ULiteralExpression (value = "inB class")]
[1]:[UPolyadicExpression (operator = +)]
[1]:[ULiteralExpression (value = "inB class")]
[1]:[UIdentifier (Identifier (InB))]
[1]:[UExpressionList (class_body)]
@@ -41,7 +41,7 @@
[1]:[UTypeReferenceExpression (name = MyAnnotation)]
[1]:[USimpleNameReferenceExpression (identifier = MyAnnotation)]
[1]:[UIdentifier (Identifier (MyAnnotation))]
[1]:[ULiteralExpression (value = "companion")]
[1]:[UPolyadicExpression (operator = +)]
[1]:[ULiteralExpression (value = "companion")]
[1]:[UIdentifier (Identifier (object))]
[1]:[UExpressionList (class_body)]
@@ -51,6 +51,6 @@
[1]:[UTypeReferenceExpression (name = MyAnnotation)]
[1]:[USimpleNameReferenceExpression (identifier = MyAnnotation)]
[1]:[UIdentifier (Identifier (MyAnnotation))]
[1]:[ULiteralExpression (value = "object")]
[1]:[UPolyadicExpression (operator = +)]
[1]:[ULiteralExpression (value = "object")]
[1]:[UIdentifier (Identifier (Obj))]
+4
View File
@@ -7,6 +7,7 @@ UFile (package = )
UClass (name = B)
UAnnotation (fqName = MyAnnotation)
UNamedExpression (name = text)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "class")
UField (name = Companion)
UAnnotation (fqName = null)
@@ -14,16 +15,19 @@ UFile (package = )
UClass (name = InB)
UAnnotation (fqName = MyAnnotation)
UNamedExpression (name = text)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "inB class")
UMethod (name = InB)
UClass (name = Companion)
UAnnotation (fqName = MyAnnotation)
UNamedExpression (name = text)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "companion")
UMethod (name = Companion)
UClass (name = Obj)
UAnnotation (fqName = MyAnnotation)
UNamedExpression (name = text)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "object")
UField (name = INSTANCE)
UAnnotation (fqName = null)
@@ -33,6 +33,7 @@ UFile (package = )
ULiteralExpression (value = 10)
UExpressionList (super_delegation)
UTypeReferenceExpression (name = java.lang.CharSequence)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "abc")
UMethod (name = Derived)
UParameter (name = b)
@@ -33,6 +33,7 @@ UFile (package = )
ULiteralExpression (value = 10)
UExpressionList (super_delegation)
UTypeReferenceExpression (name = java.lang.CharSequence)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "abc")
UMethod (name = Derived)
UParameter (name = b)
+1
View File
@@ -3,6 +3,7 @@ UFile (package = )
UMethod (name = bar)
UBlockExpression
UReturnExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "Hello!")
UClass (name = Baz)
UMethod (name = Baz)
+1
View File
@@ -10,5 +10,6 @@ UFile (package = test.pkg)
USimpleNameReferenceExpression (identifier = DeprecationLevel)
USimpleNameReferenceExpression (identifier = HIDDEN)
UNamedExpression (name = message)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "nothing")
UBlockExpression
@@ -8,6 +8,7 @@ UFile (package = )
ULocalVariable (name = var268d41a5)
UAnnotation (fqName = null)
UBinaryExpression (operator = <other>)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "foo")
ULiteralExpression (value = 1)
ULocalVariable (name = a)
@@ -29,6 +30,7 @@ UFile (package = )
UAnnotation (fqName = null)
UAnnotation (fqName = kotlin.Suppress)
UNamedExpression (name = names)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "UNCHECKED_CAST")
UBinaryExpressionWithType
USimpleNameReferenceExpression (identifier = data)
+2
View File
@@ -24,6 +24,7 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1))
UIdentifier (Identifier (foo))
USimpleNameReferenceExpression (identifier = foo, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "Lorem ipsum")
UIfExpression
UBinaryExpression (operator = !=)
@@ -33,6 +34,7 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1))
UIdentifier (Identifier (foo))
USimpleNameReferenceExpression (identifier = foo, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "dolor sit amet")
UIfExpression
UBinaryExpression (operator = !=)
@@ -5,11 +5,13 @@ UFile (package = )
UEnumConstant (name = SHEET)
UAnnotation (fqName = null)
USimpleNameReferenceExpression (identifier = Style)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "foo")
UClass (name = SHEET)
UMethod (name = getExitAnimation)
UBlockExpression
UReturnExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "bar")
UMethod (name = SHEET)
UMethod (name = getExitAnimation)
+2
View File
@@ -3,11 +3,13 @@ UFile (package = )
UEnumConstant (name = SHEET)
UAnnotation (fqName = null)
USimpleNameReferenceExpression (identifier = Style)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "foo")
UClass (name = null)
UMethod (name = getExitAnimation)
UBlockExpression
UReturnExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "bar")
UMethod (name = SHEET)
UField (name = value)
@@ -5,14 +5,17 @@ UFile (package = )
UEnumConstant (name = SYSTEM)
UAnnotation (fqName = null)
USimpleNameReferenceExpression (identifier = Style)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "system")
UEnumConstant (name = USER)
UAnnotation (fqName = null)
USimpleNameReferenceExpression (identifier = Style)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "user")
UEnumConstant (name = INTERNAL)
UAnnotation (fqName = null)
USimpleNameReferenceExpression (identifier = Style)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "internal")
UEnumConstant (name = UNKNOWN)
UAnnotation (fqName = null)
@@ -3,14 +3,17 @@ UFile (package = )
UEnumConstant (name = SYSTEM)
UAnnotation (fqName = null)
USimpleNameReferenceExpression (identifier = Style)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "system")
UEnumConstant (name = USER)
UAnnotation (fqName = null)
USimpleNameReferenceExpression (identifier = Style)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "user")
UEnumConstant (name = INTERNAL)
UAnnotation (fqName = null)
USimpleNameReferenceExpression (identifier = Style)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "internal")
UEnumConstant (name = UNKNOWN)
UAnnotation (fqName = null)
+2
View File
@@ -6,7 +6,9 @@ UFile (package = )
ULocalVariable (name = x)
UIfExpression
UBinaryExpression (operator = !=)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "abc")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "def")
ULiteralExpression (value = 1)
ULiteralExpression (value = 0)
+4
View File
@@ -60,14 +60,17 @@ UFile (package = org.jetbrains.uast.kotlin)
USimpleNameReferenceExpression (identifier = a)
ULiteralExpression (value = 5)
UReturnExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "5")
UIfExpression
UBinaryExpression (operator = >)
USimpleNameReferenceExpression (identifier = a)
ULiteralExpression (value = 0)
UReturnExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "1")
UReturnExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "2")
UDeclarationsExpression
ULocalVariable (name = lam5)
@@ -77,6 +80,7 @@ UFile (package = org.jetbrains.uast.kotlin)
UBlockExpression
UReturnExpression
UBinaryExpression (operator = +)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "a")
USimpleNameReferenceExpression (identifier = a)
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1))
@@ -5,5 +5,6 @@ UFile (package = )
UDeclarationsExpression
ULocalVariable (name = bar)
UAnnotation (fqName = TestAnnotation)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "lorem ipsum")
UClass (name = TestAnnotation)
+12 -1
View File
@@ -12,6 +12,7 @@ UFile (package = )
ULiteralExpression (value = 1)
UParameter (name = d)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "aaa")
UBlockExpression
UMethod (name = withReceiver)
@@ -32,8 +33,10 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1))
UIdentifier (Identifier (withDefault))
USimpleNameReferenceExpression (identifier = withDefault, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "bbb")
UQualifiedReferenceExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "abc")
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 2))
UIdentifier (Identifier (withReceiver))
@@ -50,7 +53,9 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 2))
UIdentifier (Identifier (unresolvedMethod))
USimpleNameReferenceExpression (identifier = <anonymous class>, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "param1")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "param2")
UQualifiedReferenceExpression
UQualifiedReferenceExpression
@@ -61,6 +66,7 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 4))
UIdentifier (Identifier (format))
USimpleNameReferenceExpression (identifier = format, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "%i %i %i")
ULiteralExpression (value = 1)
ULiteralExpression (value = 2)
@@ -74,6 +80,7 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 2))
UIdentifier (Identifier (format))
USimpleNameReferenceExpression (identifier = format, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "%i %i %i")
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 3))
UIdentifier (Identifier (arrayOf))
@@ -90,6 +97,7 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 3))
UIdentifier (Identifier (format))
USimpleNameReferenceExpression (identifier = format, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "%i %i %i")
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 3))
UIdentifier (Identifier (arrayOf))
@@ -112,10 +120,11 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 2))
UIdentifier (Identifier (format))
USimpleNameReferenceExpression (identifier = format, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "%i %i %i")
UQualifiedReferenceExpression
UQualifiedReferenceExpression
ULiteralExpression (value = "")
UPolyadicExpression (value = "")
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1))
UIdentifier (Identifier (chunked))
USimpleNameReferenceExpression (identifier = chunked, resolvesTo = null)
@@ -132,6 +141,7 @@ UFile (package = )
ULambdaExpression
UBlockExpression
UQualifiedReferenceExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "def")
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 2))
UIdentifier (Identifier (with2Receivers))
@@ -142,6 +152,7 @@ UFile (package = )
UBlockExpression
UObjectLiteralExpression
ULiteralExpression (value = 1)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "foo")
UClass (name = null)
UMethod (name = )
+12 -1
View File
@@ -12,6 +12,7 @@ UFile (package = )
ULiteralExpression (value = 1)
UParameter (name = d)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "aaa")
UBlockExpression
UMethod (name = withReceiver)
@@ -32,8 +33,10 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1))
UIdentifier (Identifier (withDefault))
USimpleNameReferenceExpression (identifier = withDefault, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "bbb")
UQualifiedReferenceExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "abc")
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 2))
UIdentifier (Identifier (withReceiver))
@@ -50,7 +53,9 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 2))
UIdentifier (Identifier (unresolvedMethod))
USimpleNameReferenceExpression (identifier = <anonymous class>, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "param1")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "param2")
UQualifiedReferenceExpression
UQualifiedReferenceExpression
@@ -61,6 +66,7 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 4))
UIdentifier (Identifier (format))
USimpleNameReferenceExpression (identifier = format, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "%i %i %i")
ULiteralExpression (value = 1)
ULiteralExpression (value = 2)
@@ -74,6 +80,7 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 2))
UIdentifier (Identifier (format))
USimpleNameReferenceExpression (identifier = format, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "%i %i %i")
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 3))
UIdentifier (Identifier (arrayOf))
@@ -90,6 +97,7 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 3))
UIdentifier (Identifier (format))
USimpleNameReferenceExpression (identifier = format, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "%i %i %i")
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 3))
UIdentifier (Identifier (arrayOf))
@@ -112,10 +120,11 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 2))
UIdentifier (Identifier (format))
USimpleNameReferenceExpression (identifier = format, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "%i %i %i")
UQualifiedReferenceExpression
UQualifiedReferenceExpression
ULiteralExpression (value = "")
UPolyadicExpression (value = "")
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1))
UIdentifier (Identifier (chunked))
USimpleNameReferenceExpression (identifier = chunked, resolvesTo = null)
@@ -132,6 +141,7 @@ UFile (package = )
ULambdaExpression
UBlockExpression
UQualifiedReferenceExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "def")
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 2))
UIdentifier (Identifier (with2Receivers))
@@ -142,6 +152,7 @@ UFile (package = )
UBlockExpression
UObjectLiteralExpression
ULiteralExpression (value = 1)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "foo")
UClass (name = null)
UMethod (name = ParametersDisorderKt$objectLiteral$1)
+2
View File
@@ -8,6 +8,7 @@ UFile (package = )
ULambdaExpression
UBlockExpression
UReturnExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "/sdcard")
UField (name = annotatedDelegate$delegate)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
@@ -32,5 +33,6 @@ UFile (package = )
ULambdaExpression
UBlockExpression
UReturnExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "/sdcard")
UMethod (name = getAnnotatedDelegate)
@@ -2,6 +2,7 @@ UFile (package = )
UClass (name = TestPropertyInitializer)
UField (name = withSetter)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "/sdcard")
UMethod (name = getWithSetter)
UBlockExpression
@@ -2,6 +2,7 @@ UFile (package = )
UClass (name = PropertyInitializerWithoutSetterKt)
UField (name = withoutSetter)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "/sdcard")
UMethod (name = getWithoutSetter)
UBlockExpression
@@ -2,6 +2,7 @@ UFile (package = )
UClass (name = PropertyInitializerWithoutSetterKt)
UField (name = withoutSetter)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "/sdcard")
UMethod (name = getWithoutSetter)
UBlockExpression
+2
View File
@@ -2,12 +2,14 @@ UFile (package = )
UClass (name = Simple)
UField (name = property)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "Mary")
UMethod (name = method)
UBlockExpression
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1))
UIdentifier (Identifier (println))
USimpleNameReferenceExpression (identifier = println, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "Hello, world!")
UMethod (name = getProperty)
UMethod (name = Simple)
+2
View File
@@ -2,12 +2,14 @@ UFile (package = ) [public final class Simple {...]
UClass (name = Simple) [public final class Simple {...}]
UField (name = property) [@org.jetbrains.annotations.NotNull private final var property: java.lang.String = "Mary"]
UAnnotation (fqName = org.jetbrains.annotations.NotNull) [@org.jetbrains.annotations.NotNull]
UPolyadicExpression (operator = +) ["Mary"] = "Mary"
ULiteralExpression (value = "Mary") ["Mary"] = "Mary"
UMethod (name = method) [public final fun method() : void {...}]
UBlockExpression [{...}] = external println("Hello, world!")("Hello, world!")
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1)) [println("Hello, world!")] = external println("Hello, world!")("Hello, world!")
UIdentifier (Identifier (println)) [UIdentifier (Identifier (println))]
USimpleNameReferenceExpression (identifier = println, resolvesTo = null) [println] = external println("Hello, world!")("Hello, world!")
UPolyadicExpression (operator = +) ["Hello, world!"] = "Hello, world!"
ULiteralExpression (value = "Hello, world!") ["Hello, world!"] = "Hello, world!"
UMethod (name = getProperty) [public final fun getProperty() : java.lang.String = UastEmptyExpression]
UMethod (name = Simple) [public fun Simple() = UastEmptyExpression]
+2
View File
@@ -22,6 +22,7 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1))
UIdentifier (Identifier (println))
USimpleNameReferenceExpression (identifier = println, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "Hello World!")
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1))
UIdentifier (Identifier (getBarOrNull))
@@ -30,6 +31,7 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1))
UIdentifier (Identifier (println))
USimpleNameReferenceExpression (identifier = println, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "Goodbye World!")
UClass (name = Bar)
UField (name = b)
+3
View File
@@ -2,12 +2,15 @@ UFile (package = )
UClass (name = StringTemplateKt)
UField (name = foo)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "lorem")
UField (name = bar)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "ipsum")
UField (name = baz)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "dolor")
UField (name = foobarbaz)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
+3
View File
@@ -2,12 +2,15 @@ UFile (package = ) [public final class StringTemplateKt {...]
UClass (name = StringTemplateKt) [public final class StringTemplateKt {...}]
UField (name = foo) [@org.jetbrains.annotations.NotNull private static final var foo: java.lang.String = "lorem"]
UAnnotation (fqName = org.jetbrains.annotations.NotNull) [@org.jetbrains.annotations.NotNull]
UPolyadicExpression (operator = +) ["lorem"] : PsiType:String
ULiteralExpression (value = "lorem") ["lorem"] : PsiType:String
UField (name = bar) [@org.jetbrains.annotations.NotNull private static final var bar: java.lang.String = "ipsum"]
UAnnotation (fqName = org.jetbrains.annotations.NotNull) [@org.jetbrains.annotations.NotNull]
UPolyadicExpression (operator = +) ["ipsum"] : PsiType:String
ULiteralExpression (value = "ipsum") ["ipsum"] : PsiType:String
UField (name = baz) [@org.jetbrains.annotations.NotNull private static final var baz: java.lang.String = "dolor"]
UAnnotation (fqName = org.jetbrains.annotations.NotNull) [@org.jetbrains.annotations.NotNull]
UPolyadicExpression (operator = +) ["dolor"] : PsiType:String
ULiteralExpression (value = "dolor") ["dolor"] : PsiType:String
UField (name = foobarbaz) [@org.jetbrains.annotations.NotNull private static final var foobarbaz: java.lang.String = foo + " " + bar + " " + baz]
UAnnotation (fqName = org.jetbrains.annotations.NotNull) [@org.jetbrains.annotations.NotNull]
@@ -2,19 +2,26 @@ UFile (package = )
UClass (name = StringTemplateComplexKt)
UField (name = muchRecur)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UPolyadicExpression (operator = +)
UPolyadicExpression (operator = +)
UPolyadicExpression (operator = +)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "abc")
UField (name = case4)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "a ")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "literal")
ULiteralExpression (value = " z")
UField (name = case5)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "a ")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "literal")
ULiteralExpression (value = " ")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "literal")
ULiteralExpression (value = " z")
UField (name = literalInLiteral)
@@ -49,15 +56,18 @@ UFile (package = )
ULiteralExpression (value = 0)
UBlockExpression
UReturnExpression
UPolyadicExpression (operator = +)
USimpleNameReferenceExpression (identifier = i)
UMethod (name = foo)
UBlockExpression
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1))
UIdentifier (Identifier (println))
USimpleNameReferenceExpression (identifier = println, resolvesTo = null)
UPolyadicExpression (operator = +)
USimpleNameReferenceExpression (identifier = baz)
UDeclarationsExpression
ULocalVariable (name = template1)
UPolyadicExpression (operator = +)
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 0))
UIdentifier (Identifier (simpleForTemplate))
USimpleNameReferenceExpression (identifier = simpleForTemplate, resolvesTo = null)
@@ -2,19 +2,26 @@ UFile (package = ) [public final class StringTemplateComplexKt {...]
UClass (name = StringTemplateComplexKt) [public final class StringTemplateComplexKt {...}]
UField (name = muchRecur) [@org.jetbrains.annotations.NotNull private static final var muchRecur: java.lang.String = "abc"]
UAnnotation (fqName = org.jetbrains.annotations.NotNull) [@org.jetbrains.annotations.NotNull]
UPolyadicExpression (operator = +) ["abc"] : PsiType:String
UPolyadicExpression (operator = +) ["abc"] : PsiType:String
UPolyadicExpression (operator = +) ["abc"] : PsiType:String
UPolyadicExpression (operator = +) ["abc"] : PsiType:String
ULiteralExpression (value = "abc") ["abc"] : PsiType:String
UField (name = case4) [@org.jetbrains.annotations.NotNull private static final var case4: java.lang.String = "a " + "literal" + " z"]
UAnnotation (fqName = org.jetbrains.annotations.NotNull) [@org.jetbrains.annotations.NotNull]
UPolyadicExpression (operator = +) ["a " + "literal" + " z"] : PsiType:String
ULiteralExpression (value = "a ") ["a "] : PsiType:String
UPolyadicExpression (operator = +) ["literal"] : PsiType:String
ULiteralExpression (value = "literal") ["literal"] : PsiType:String
ULiteralExpression (value = " z") [" z"] : PsiType:String
UField (name = case5) [@org.jetbrains.annotations.NotNull private static final var case5: java.lang.String = "a " + "literal" + " " + "literal" + " z"]
UAnnotation (fqName = org.jetbrains.annotations.NotNull) [@org.jetbrains.annotations.NotNull]
UPolyadicExpression (operator = +) ["a " + "literal" + " " + "literal" + " z"] : PsiType:String
ULiteralExpression (value = "a ") ["a "] : PsiType:String
UPolyadicExpression (operator = +) ["literal"] : PsiType:String
ULiteralExpression (value = "literal") ["literal"] : PsiType:String
ULiteralExpression (value = " ") [" "] : PsiType:String
UPolyadicExpression (operator = +) ["literal"] : PsiType:String
ULiteralExpression (value = "literal") ["literal"] : PsiType:String
ULiteralExpression (value = " z") [" z"] : PsiType:String
UField (name = literalInLiteral) [@org.jetbrains.annotations.NotNull private static final var literalInLiteral: java.lang.String = "a " + "literal" + case4 + " z"]
@@ -49,15 +56,18 @@ UFile (package = ) [public final class StringTemplateComplexKt {...]
ULiteralExpression (value = 0) [0] : PsiType:int
UBlockExpression [{...}]
UReturnExpression [return i]
UPolyadicExpression (operator = +) [i] : PsiType:String
USimpleNameReferenceExpression (identifier = i) [i] : PsiType:int
UMethod (name = foo) [public static final fun foo() : void {...}]
UBlockExpression [{...}] : PsiType:void
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 1)) [println(baz)] : PsiType:void
UIdentifier (Identifier (println)) [UIdentifier (Identifier (println))]
USimpleNameReferenceExpression (identifier = println, resolvesTo = null) [println] : PsiType:void
UPolyadicExpression (operator = +) [baz] : PsiType:String
USimpleNameReferenceExpression (identifier = baz) [baz]
UDeclarationsExpression [var template1: java.lang.String = simpleForTemplate()]
ULocalVariable (name = template1) [var template1: java.lang.String = simpleForTemplate()]
UPolyadicExpression (operator = +) [simpleForTemplate()] : PsiType:String
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 0)) [simpleForTemplate()] : PsiType:String
UIdentifier (Identifier (simpleForTemplate)) [UIdentifier (Identifier (simpleForTemplate))]
USimpleNameReferenceExpression (identifier = simpleForTemplate, resolvesTo = null) [simpleForTemplate] : PsiType:String
+4
View File
@@ -3,6 +3,7 @@ UFile (package = )
UField (name = anon)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UObjectLiteralExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "textForAnon")
UClass (name = null)
UMethod (name = bar)
@@ -11,6 +12,7 @@ UFile (package = )
UIdentifier (Identifier (cons))
USimpleNameReferenceExpression (identifier = cons, resolvesTo = null)
UObjectLiteralExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "inner literal")
UClass (name = null)
UMethod (name = )
@@ -21,6 +23,7 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='constructor_call'), argCount = 1))
UIdentifier (Identifier (A))
USimpleNameReferenceExpression (identifier = <init>, resolvesTo = A)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "inner class")
UMethod (name = getAnon)
UMethod (name = cons)
@@ -97,4 +100,5 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='constructor_call'), argCount = 1))
UIdentifier (Identifier (A))
USimpleNameReferenceExpression (identifier = <init>, resolvesTo = A)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "text")
+4
View File
@@ -3,6 +3,7 @@ UFile (package = )
UField (name = anon)
UAnnotation (fqName = org.jetbrains.annotations.NotNull)
UObjectLiteralExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "textForAnon")
UClass (name = null)
UMethod (name = bar)
@@ -11,6 +12,7 @@ UFile (package = )
UIdentifier (Identifier (cons))
USimpleNameReferenceExpression (identifier = cons, resolvesTo = null)
UObjectLiteralExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "inner literal")
UClass (name = null)
UMethod (name = SuperCallsKt$anon$1$bar$1)
@@ -21,6 +23,7 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='constructor_call'), argCount = 1))
UIdentifier (Identifier (A))
USimpleNameReferenceExpression (identifier = <init>, resolvesTo = A)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "inner class")
UMethod (name = getAnon)
UMethod (name = cons)
@@ -97,4 +100,5 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='constructor_call'), argCount = 1))
UIdentifier (Identifier (A))
USimpleNameReferenceExpression (identifier = <init>, resolvesTo = A)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "text")
+2
View File
@@ -6,9 +6,11 @@ UFile (package = )
UBlockExpression
UDeclarationsExpression
ULocalVariable (name = varWithType)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "Not Null")
UDeclarationsExpression
ULocalVariable (name = varWithoutType)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "lorem ipsum")
UDeclarationsExpression
ULocalVariable (name = result)
@@ -36,5 +36,5 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='constructor_call'), argCount = 1))
UIdentifier (Identifier (UnsupportedOperationException))
USimpleNameReferenceExpression (identifier = <init>, resolvesTo = UnsupportedOperationException)
ULiteralExpression (value = "")
UPolyadicExpression (value = "")
UMethod (name = )
@@ -36,5 +36,5 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='constructor_call'), argCount = 1))
UIdentifier (Identifier (UnsupportedOperationException))
USimpleNameReferenceExpression (identifier = <init>, resolvesTo = UnsupportedOperationException)
ULiteralExpression (value = "")
UPolyadicExpression (value = "")
UMethod (name = Model$1$1)
@@ -36,5 +36,5 @@ UFile (package = ) [public abstract interface Callback {...]
UCallExpression (kind = UastCallKind(name='constructor_call'), argCount = 1)) [<init>("")] : PsiType:UnsupportedOperationException
UIdentifier (Identifier (UnsupportedOperationException)) [UIdentifier (Identifier (UnsupportedOperationException))]
USimpleNameReferenceExpression (identifier = <init>, resolvesTo = UnsupportedOperationException) [<init>] : PsiType:UnsupportedOperationException
ULiteralExpression (value = "") [""] : PsiType:String
UPolyadicExpression (value = "") [""] : PsiType:String
UMethod (name = Model$1$1) [fun Model$1$1() = UastEmptyExpression]
@@ -9,15 +9,19 @@ UFile (package = )
UCallExpression (kind = UastCallKind(name='method_call'), argCount = 2))
UIdentifier (Identifier (listOf))
USimpleNameReferenceExpression (identifier = listOf, resolvesTo = null)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "1")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "2")
USwitchExpression
USimpleNameReferenceExpression (identifier = string)
UExpressionList (when)
USwitchClauseExpressionWithBody
UPolyadicExpression (operator = +)
ULiteralExpression (value = "aaaa")
UExpressionList (when_entry)
UReturnExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "bindingContext")
UBreakExpression (label = null)
USwitchClauseExpressionWithBody
+1
View File
@@ -20,5 +20,6 @@ UFile (package = )
USimpleNameReferenceExpression (identifier = it)
UTypeReferenceExpression (name = java.lang.String)
UExpressionList (when_entry)
UPolyadicExpression (operator = +)
ULiteralExpression (value = "<error>")
UBreakExpression (label = null)
@@ -11,12 +11,15 @@ UFile (package = )
USimpleNameReferenceExpression (identifier = a)
UExpressionList (when)
USwitchClauseExpressionWithBody
UPolyadicExpression (operator = +)
ULiteralExpression (value = "abc")
UExpressionList (when_entry)
ULiteralExpression (value = 1)
UBreakExpression (label = null)
USwitchClauseExpressionWithBody
UPolyadicExpression (operator = +)
ULiteralExpression (value = "def")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "ghi")
UExpressionList (when_entry)
ULiteralExpression (value = 2)
@@ -29,5 +32,7 @@ UFile (package = )
UMethod (name = getB)
UMethod (name = <no name provided>)
UBlockExpression
UPolyadicExpression (operator = +)
ULiteralExpression (value = "abc1")
UPolyadicExpression (operator = +)
ULiteralExpression (value = "def1")