Skip to main content
Version: 3.4

NewList 列表构造器

1. 结构声明

class NewList extends LogicItem {
typeAnnotation?: TypeAnnotation;
items: Array<LogicItem>;
}

2. 节点示例

(1) 示例

AST 如下:

{
"concept": "NewList",
"items": [
{
"concept": "StringLiteral",
"value": "选项1"
},
{
"concept": "StringLiteral",
"value": "选项2"
},
{
"concept": "StringLiteral",
"value": "选项3"
}
]
}