"type" is not a keyword anymore ("typealias" reserved instead)
This commit is contained in:
@@ -3,7 +3,7 @@ fun foo() {
|
||||
fun foo()
|
||||
class foo
|
||||
|
||||
type x = t
|
||||
typealias x = t
|
||||
var r
|
||||
|
||||
[a] var foo = 4
|
||||
|
||||
@@ -31,7 +31,7 @@ JetFile: EOLsOnRollback.kt
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiWhiteSpace('\n\n ')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('x')
|
||||
PsiWhiteSpace(' ')
|
||||
|
||||
@@ -1,24 +1,24 @@
|
||||
type f = ([a] a) -> b
|
||||
type f = (a) -> b
|
||||
type f = () -> [x] b
|
||||
type f = () -> Unit
|
||||
typealias f = ([a] a) -> b
|
||||
typealias f = (a) -> b
|
||||
typealias f = () -> [x] b
|
||||
typealias f = () -> Unit
|
||||
|
||||
type f = (a : [a] a) -> b
|
||||
type f = (a : a) -> b
|
||||
type f = () -> b
|
||||
type f = () -> Unit
|
||||
typealias f = (a : [a] a) -> b
|
||||
typealias f = (a : a) -> b
|
||||
typealias f = () -> b
|
||||
typealias f = () -> Unit
|
||||
|
||||
type f = (a : [a] a, foo, x : bar) -> b
|
||||
type f = (foo, a : a) -> b
|
||||
type f = (foo, a : (a) -> b) -> b
|
||||
type f = (foo, a : (a) -> b) -> () -> Unit
|
||||
typealias f = (a : [a] a, foo, x : bar) -> b
|
||||
typealias f = (foo, a : a) -> b
|
||||
typealias f = (foo, a : (a) -> b) -> b
|
||||
typealias f = (foo, a : (a) -> b) -> () -> Unit
|
||||
|
||||
//type f = (ref foo, ref a : (ref a) -> b) -> () -> Unit
|
||||
|
||||
type f = T.() -> Unit
|
||||
type f = T.T.() -> Unit
|
||||
type f = T<A, B>.T<x>.() -> Unit
|
||||
typealias f = T.() -> Unit
|
||||
typealias f = T.T.() -> Unit
|
||||
typealias f = T<A, B>.T<x>.() -> Unit
|
||||
|
||||
type f = [a] T.() -> Unit
|
||||
type f = [a] T.T.() -> Unit
|
||||
type f = [a] T<A, B>.T<x>.() -> Unit
|
||||
typealias f = [a] T.() -> Unit
|
||||
typealias f = [a] T.T.() -> Unit
|
||||
typealias f = [a] T<A, B>.T<x>.() -> Unit
|
||||
|
||||
@@ -2,7 +2,7 @@ JetFile: FunctionTypes.kt
|
||||
PACKAGE_DIRECTIVE
|
||||
<empty list>
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -38,7 +38,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('b')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -63,7 +63,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('b')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -93,7 +93,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('b')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -113,7 +113,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('Unit')
|
||||
PsiWhiteSpace('\n\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -152,7 +152,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('b')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -181,7 +181,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('b')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -201,7 +201,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('b')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -221,7 +221,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('Unit')
|
||||
PsiWhiteSpace('\n\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -278,7 +278,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('b')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -314,7 +314,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('b')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -363,7 +363,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('b')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -422,7 +422,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiComment(EOL_COMMENT)('//type f = (ref foo, ref a : (ref a) -> b) -> () -> Unit')
|
||||
PsiWhiteSpace('\n\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -448,7 +448,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('Unit')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -478,7 +478,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('Unit')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -531,7 +531,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('Unit')
|
||||
PsiWhiteSpace('\n\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -567,7 +567,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('Unit')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -607,7 +607,7 @@ JetFile: FunctionTypes.kt
|
||||
PsiElement(IDENTIFIER)('Unit')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
|
||||
@@ -1 +1 @@
|
||||
type f = (a, ) -> b
|
||||
typealias f = (a, ) -> b
|
||||
|
||||
@@ -2,7 +2,7 @@ JetFile: FunctionTypes_ERR.kt
|
||||
PACKAGE_DIRECTIVE
|
||||
<empty list>
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
|
||||
@@ -6,6 +6,6 @@ fun foo() {
|
||||
|
||||
out val foo = 5
|
||||
[a] var foo = 4
|
||||
type f = T.() -> Unit
|
||||
typealias f = T.() -> Unit
|
||||
|
||||
}
|
||||
|
||||
@@ -97,7 +97,7 @@ JetFile: LocalDeclarations.kt
|
||||
PsiElement(INTEGER_LITERAL)('4')
|
||||
PsiWhiteSpace('\n ')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
|
||||
@@ -13,7 +13,7 @@ class foo {
|
||||
|
||||
var f
|
||||
|
||||
type foo = bar
|
||||
typealias foo = bar
|
||||
|
||||
}
|
||||
|
||||
@@ -46,7 +46,7 @@ class foo {
|
||||
|
||||
var f
|
||||
|
||||
type foo = bar
|
||||
typealias foo = bar
|
||||
|
||||
}
|
||||
|
||||
@@ -56,7 +56,7 @@ class foo {
|
||||
|
||||
var f
|
||||
|
||||
type foo = bar
|
||||
typealias foo = bar
|
||||
|
||||
class object {
|
||||
|
||||
|
||||
@@ -56,7 +56,7 @@ JetFile: SimpleClassMembers.kt
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace('\n\n ')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -240,7 +240,7 @@ JetFile: SimpleClassMembers.kt
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace('\n\n ')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -272,7 +272,7 @@ JetFile: SimpleClassMembers.kt
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace('\n\n ')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiWhiteSpace(' ')
|
||||
|
||||
@@ -12,6 +12,6 @@ class foo {
|
||||
|
||||
var f
|
||||
|
||||
type foo = ;
|
||||
typealias foo = ;
|
||||
|
||||
}
|
||||
@@ -60,7 +60,7 @@ JetFile: SimpleClassMembers_ERR.kt
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace('\n\n ')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiWhiteSpace(' ')
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
package foo.bar.goo
|
||||
|
||||
type foo = bar
|
||||
type foo<T> = bar
|
||||
type foo<T : foo> = bar
|
||||
type foo<A, B> = bar
|
||||
type foo<A, B : A> = bar
|
||||
typealias foo = bar
|
||||
typealias foo<T> = bar
|
||||
typealias foo<T : foo> = bar
|
||||
typealias foo<A, B> = bar
|
||||
typealias foo<A, B : A> = bar
|
||||
|
||||
type foo = bar ;
|
||||
type foo<T> = bar ;
|
||||
typealias foo = bar ;
|
||||
typealias foo<T> = bar ;
|
||||
|
||||
type foo<T : foo> = bar ;
|
||||
type foo<A, B> = bar ;
|
||||
type foo<A, B : A> = bar ;
|
||||
typealias foo<T : foo> = bar ;
|
||||
typealias foo<A, B> = bar ;
|
||||
typealias foo<A, B : A> = bar ;
|
||||
|
||||
@@ -14,7 +14,7 @@ JetFile: TypeDef.kt
|
||||
PsiElement(IDENTIFIER)('goo')
|
||||
PsiWhiteSpace('\n\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -26,7 +26,7 @@ JetFile: TypeDef.kt
|
||||
PsiElement(IDENTIFIER)('bar')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -43,7 +43,7 @@ JetFile: TypeDef.kt
|
||||
PsiElement(IDENTIFIER)('bar')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -67,7 +67,7 @@ JetFile: TypeDef.kt
|
||||
PsiElement(IDENTIFIER)('bar')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -88,7 +88,7 @@ JetFile: TypeDef.kt
|
||||
PsiElement(IDENTIFIER)('bar')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -116,7 +116,7 @@ JetFile: TypeDef.kt
|
||||
PsiElement(IDENTIFIER)('bar')
|
||||
PsiWhiteSpace('\n\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -130,7 +130,7 @@ JetFile: TypeDef.kt
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -149,7 +149,7 @@ JetFile: TypeDef.kt
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiWhiteSpace('\n\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -175,7 +175,7 @@ JetFile: TypeDef.kt
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -198,7 +198,7 @@ JetFile: TypeDef.kt
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
TYPE_PARAMETER_LIST
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
type
|
||||
type foo
|
||||
type foo =
|
||||
type ;
|
||||
type foo ;
|
||||
type foo = ;
|
||||
type = foo
|
||||
type =
|
||||
type = foo ;
|
||||
type = ;
|
||||
typealias
|
||||
typealias foo
|
||||
typealias foo =
|
||||
typealias ;
|
||||
typealias foo ;
|
||||
typealias foo = ;
|
||||
typealias = foo
|
||||
typealias =
|
||||
typealias = foo ;
|
||||
typealias = ;
|
||||
|
||||
type foo<> = bar
|
||||
type foo<T, > = bar
|
||||
type foo<A : , B> = bar
|
||||
typealias foo<> = bar
|
||||
typealias foo<T, > = bar
|
||||
typealias foo<A : , B> = bar
|
||||
|
||||
class
|
||||
type foo = bar
|
||||
typealias foo = bar
|
||||
@@ -2,7 +2,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PACKAGE_DIRECTIVE
|
||||
<empty list>
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiErrorElement:Type name expected
|
||||
<empty list>
|
||||
PsiWhiteSpace('\n')
|
||||
@@ -10,7 +10,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PsiErrorElement:Type expected
|
||||
<empty list>
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiErrorElement:Expecting '='
|
||||
@@ -20,7 +20,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PsiErrorElement:Type expected
|
||||
<empty list>
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -30,7 +30,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PsiErrorElement:Type expected
|
||||
<empty list>
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiErrorElement:Type name expected
|
||||
<empty list>
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -40,7 +40,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiErrorElement:Expecting '='
|
||||
@@ -52,7 +52,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -64,7 +64,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiErrorElement:Type name expected
|
||||
<empty list>
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -76,7 +76,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiErrorElement:Type name expected
|
||||
<empty list>
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -86,7 +86,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PsiErrorElement:Type expected
|
||||
<empty list>
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiErrorElement:Type name expected
|
||||
<empty list>
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -100,7 +100,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiErrorElement:Type name expected
|
||||
<empty list>
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -112,7 +112,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PsiElement(SEMICOLON)(';')
|
||||
PsiWhiteSpace('\n\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -129,7 +129,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PsiElement(IDENTIFIER)('bar')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -150,7 +150,7 @@ JetFile: TypeDef_ERR.kt
|
||||
PsiElement(IDENTIFIER)('bar')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -182,7 +182,7 @@ JetFile: TypeDef_ERR.kt
|
||||
<empty list>
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('foo')
|
||||
PsiWhiteSpace(' ')
|
||||
|
||||
@@ -5,7 +5,7 @@ foo bar(1) buzz<T>(1) zoo object B
|
||||
foo bar(1) buzz<T>(1) zoo fun a() {}
|
||||
foo bar(1) buzz<T>(1) zoo val c : Int = 0
|
||||
foo bar(1) buzz<T>(1) zoo var v : Int = 0
|
||||
foo bar(1) buzz<T>(1) zoo type T = Int
|
||||
foo bar(1) buzz<T>(1) zoo typealias T = Int
|
||||
|
||||
|
||||
class Foo {
|
||||
@@ -15,7 +15,7 @@ class Foo {
|
||||
foo bar(1) buzz<T>(1) zoo fun a() {}
|
||||
foo bar(1) buzz<T>(1) zoo val c : Int = 0
|
||||
foo bar(1) buzz<T>(1) zoo var v : Int = 0
|
||||
foo bar(1) buzz<T>(1) zoo type T = Int
|
||||
foo bar(1) buzz<T>(1) zoo typealias T = Int
|
||||
|
||||
foo bar(1) buzz<T>(1) zoo {}
|
||||
}
|
||||
|
||||
@@ -406,7 +406,7 @@ JetFile: ShortAnnotations.kt
|
||||
REFERENCE_EXPRESSION
|
||||
PsiElement(IDENTIFIER)('zoo')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('T')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -836,7 +836,7 @@ JetFile: ShortAnnotations.kt
|
||||
REFERENCE_EXPRESSION
|
||||
PsiElement(IDENTIFIER)('zoo')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('T')
|
||||
PsiWhiteSpace(' ')
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
class F(a : [a] [b] B)
|
||||
|
||||
type f = [b] [x] F<[x] A, B>
|
||||
typealias f = [b] [x] F<[x] A, B>
|
||||
@@ -39,7 +39,7 @@ JetFile: TypeAnnotations.kt
|
||||
PsiElement(RPAR)(')')
|
||||
PsiWhiteSpace('\n\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
|
||||
@@ -1,24 +1,24 @@
|
||||
type f1 = (T) -> X
|
||||
typealias f1 = (T) -> X
|
||||
// type f1 = {(T) => X}
|
||||
type f2 = (T, E) -> X
|
||||
typealias f2 = (T, E) -> X
|
||||
// type f2 = {(T, E) => X}
|
||||
type f_tuple = (Pair<T, E>) -> X
|
||||
typealias f_tuple = (Pair<T, E>) -> X
|
||||
//type f_tuple = {((T, E)) => X}
|
||||
type hof = (X) -> (T) -> Y
|
||||
typealias hof = (X) -> (T) -> Y
|
||||
//type hof = { (X) => {(T) => Y} }
|
||||
type hof2 = ( (X) -> Y) -> (Y) -> Z
|
||||
typealias hof2 = ( (X) -> Y) -> (Y) -> Z
|
||||
//type hof2 = { {(X) => Y} => {(Y) => Z} }
|
||||
|
||||
|
||||
type Comparison<in T> = (a : T, b : T) -> Int
|
||||
typealias Comparison<in T> = (a : T, b : T) -> Int
|
||||
//type Comparison<in T> = {(a : T, b : T) => Int}
|
||||
type Equality<in T> = (a : T, b : T) -> Boolean
|
||||
typealias Equality<in T> = (a : T, b : T) -> Boolean
|
||||
//type Equality<in T> = {(a : T, b : T) => Boolean}
|
||||
type HashFunction<in T> = (obj : T) -> Int
|
||||
typealias HashFunction<in T> = (obj : T) -> Int
|
||||
//type HashFunction<in T> = {(obj : T) => Int}
|
||||
type Runnable = () -> Unit
|
||||
typealias Runnable = () -> Unit
|
||||
//type Runnable = {() => ()}
|
||||
type Function1<in T, out R> = (input : T) -> R
|
||||
typealias Function1<in T, out R> = (input : T) -> R
|
||||
//type Function1<in T, out R> = {(input : T) => R}
|
||||
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@ JetFile: FunctionsAndTypes.kt
|
||||
PACKAGE_DIRECTIVE
|
||||
<empty list>
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f1')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -29,7 +29,7 @@ JetFile: FunctionsAndTypes.kt
|
||||
PsiComment(EOL_COMMENT)('// type f1 = {(T) => X}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f2')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -63,7 +63,7 @@ JetFile: FunctionsAndTypes.kt
|
||||
PsiComment(EOL_COMMENT)('// type f2 = {(T, E) => X}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f_tuple')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -105,7 +105,7 @@ JetFile: FunctionsAndTypes.kt
|
||||
PsiComment(EOL_COMMENT)('//type f_tuple = {((T, E)) => X}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('hof')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -145,7 +145,7 @@ JetFile: FunctionsAndTypes.kt
|
||||
PsiComment(EOL_COMMENT)('//type hof = { (X) => {(T) => Y} }')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('hof2')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -199,7 +199,7 @@ JetFile: FunctionsAndTypes.kt
|
||||
PsiComment(EOL_COMMENT)('//type hof2 = { {(X) => Y} => {(Y) => Z} }')
|
||||
PsiWhiteSpace('\n\n\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('Comparison')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -249,7 +249,7 @@ JetFile: FunctionsAndTypes.kt
|
||||
PsiComment(EOL_COMMENT)('//type Comparison<in T> = {(a : T, b : T) => Int}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('Equality')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -299,7 +299,7 @@ JetFile: FunctionsAndTypes.kt
|
||||
PsiComment(EOL_COMMENT)('//type Equality<in T> = {(a : T, b : T) => Boolean}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('HashFunction')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -338,7 +338,7 @@ JetFile: FunctionsAndTypes.kt
|
||||
PsiComment(EOL_COMMENT)('//type HashFunction<in T> = {(obj : T) => Int}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('Runnable')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -360,7 +360,7 @@ JetFile: FunctionsAndTypes.kt
|
||||
PsiComment(EOL_COMMENT)('//type Runnable = {() => ()}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('Function1')
|
||||
TYPE_PARAMETER_LIST
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
type Comparison<in T> = (T, T) -> Int
|
||||
typealias Comparison<in T> = (T, T) -> Int
|
||||
|
||||
fun naturalOrder<in T : Comparable<T>>(a : T, b : T) : Int = a.compareTo(b)
|
||||
|
||||
@@ -8,7 +8,7 @@ enum class ComparisonResult {
|
||||
LS; EQ; GR
|
||||
}
|
||||
|
||||
type MatchableComparison<in T> = (T, T) -> ComparisonResult
|
||||
typealias MatchableComparison<in T> = (T, T) -> ComparisonResult
|
||||
|
||||
fun asMatchableComparison<T>(cmp : Comparison<T>) : MatchableComparison<T> = {(a, b) ->
|
||||
val res = cmp(a, b)
|
||||
|
||||
@@ -2,7 +2,7 @@ JetFile: Comparison.kt
|
||||
PACKAGE_DIRECTIVE
|
||||
<empty list>
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('Comparison')
|
||||
TYPE_PARAMETER_LIST
|
||||
@@ -231,7 +231,7 @@ JetFile: Comparison.kt
|
||||
PsiElement(RBRACE)('}')
|
||||
PsiWhiteSpace('\n\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('MatchableComparison')
|
||||
TYPE_PARAMETER_LIST
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
type f = {T<A, B>.T<x>.() : ()}
|
||||
type f = {{(S).() : ()}.() : ()}
|
||||
type f = {{T.() : ()}.() : ()}
|
||||
type f = {{T.T.() : ()}.() : ()}
|
||||
type f = {{T<A, B>.T<x>.() : ()}.() : ()}
|
||||
type f = {{(S).() : ()}.() : ()}
|
||||
typealias f = {T<A, B>.T<x>.() : ()}
|
||||
typealias f = {{(S).() : ()}.() : ()}
|
||||
typealias f = {{T.() : ()}.() : ()}
|
||||
typealias f = {{T.T.() : ()}.() : ()}
|
||||
typealias f = {{T<A, B>.T<x>.() : ()}.() : ()}
|
||||
typealias f = {{(S).() : ()}.() : ()}
|
||||
|
||||
type f = [a] {[a] {(S).() : ()}.() : ()}
|
||||
type f = [a] {[a] {T.() : ()}.() : ()}
|
||||
type f = [a] {[a] {T.T.() : ()}.() : ()}
|
||||
type f = [a] {[a] {T<A, B>.T<x>.() : ()}.() : ()}
|
||||
type f = [a] {[a] {(S).() : ()}.() : ()}
|
||||
typealias f = [a] {[a] {(S).() : ()}.() : ()}
|
||||
typealias f = [a] {[a] {T.() : ()}.() : ()}
|
||||
typealias f = [a] {[a] {T.T.() : ()}.() : ()}
|
||||
typealias f = [a] {[a] {T<A, B>.T<x>.() : ()}.() : ()}
|
||||
typealias f = [a] {[a] {(S).() : ()}.() : ()}
|
||||
@@ -2,7 +2,7 @@ JetFile: FunctionTypesWithFunctionReceivers.kt
|
||||
PACKAGE_DIRECTIVE
|
||||
<empty list>
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -65,7 +65,7 @@ JetFile: FunctionTypesWithFunctionReceivers.kt
|
||||
PsiElement(RBRACE)('}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -123,7 +123,7 @@ JetFile: FunctionTypesWithFunctionReceivers.kt
|
||||
PsiElement(RBRACE)('}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -177,7 +177,7 @@ JetFile: FunctionTypesWithFunctionReceivers.kt
|
||||
PsiElement(RBRACE)('}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -235,7 +235,7 @@ JetFile: FunctionTypesWithFunctionReceivers.kt
|
||||
PsiElement(RBRACE)('}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -316,7 +316,7 @@ JetFile: FunctionTypesWithFunctionReceivers.kt
|
||||
PsiElement(RBRACE)('}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -374,7 +374,7 @@ JetFile: FunctionTypesWithFunctionReceivers.kt
|
||||
PsiElement(RBRACE)('}')
|
||||
PsiWhiteSpace('\n\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -453,7 +453,7 @@ JetFile: FunctionTypesWithFunctionReceivers.kt
|
||||
PsiElement(RBRACE)('}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -528,7 +528,7 @@ JetFile: FunctionTypesWithFunctionReceivers.kt
|
||||
PsiElement(RBRACE)('}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -607,7 +607,7 @@ JetFile: FunctionTypesWithFunctionReceivers.kt
|
||||
PsiElement(RBRACE)('}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
@@ -709,7 +709,7 @@ JetFile: FunctionTypesWithFunctionReceivers.kt
|
||||
PsiElement(RBRACE)('}')
|
||||
PsiWhiteSpace('\n')
|
||||
TYPEDEF
|
||||
PsiElement(type)('type')
|
||||
PsiElement(typealias)('typealias')
|
||||
PsiWhiteSpace(' ')
|
||||
PsiElement(IDENTIFIER)('f')
|
||||
PsiWhiteSpace(' ')
|
||||
|
||||
Reference in New Issue
Block a user