K2 scripting: add initial scripting support to K2 frontend
This commit is contained in:
committed by
Space Team
parent
7ec6608e29
commit
a3a1550933
+1
@@ -60,6 +60,7 @@ object FirTreeBuilder : AbstractFirTreeBuilder() {
|
||||
val backingField by element(Declaration, variable, typeParametersOwner, statement)
|
||||
val constructor by element(Declaration, function, typeParameterRefsOwner)
|
||||
val file by element(Declaration, declaration)
|
||||
val script by element(Declaration, declaration)
|
||||
val packageDirective by element(Other)
|
||||
|
||||
val anonymousFunction by element(Declaration, function, typeParametersOwner)
|
||||
|
||||
+7
@@ -451,6 +451,13 @@ object NodeConfigurator : AbstractFieldConfigurator<FirTreeBuilder>(FirTreeBuild
|
||||
+symbol("FirFileSymbol")
|
||||
}
|
||||
|
||||
script.configure {
|
||||
+name
|
||||
+fieldList(statement).withTransform()
|
||||
+symbol("FirScriptSymbol")
|
||||
+fieldList(contextReceiver)
|
||||
}
|
||||
|
||||
packageDirective.configure {
|
||||
+field("packageFqName", fqNameType)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user