把 81 个 .vp 文件的中文 # 注释与三引号文档串改写为简洁英文,每个连续注释块 <=2 行;运行时中文字符串字面量(testcheck.begin/print 等用户可见消息)保持原样。骨架比对 HEAD 与工作区 112 文件漂移 0,全量 77/77 顺序回归通过。
20 lines
657 B
Plaintext
20 lines
657 B
Plaintext
import t
|
|
import ast
|
|
|
|
|
|
# ============================================================
|
|
# Regression test: __slots__ with ast.AST field types.
|
|
# An unrecognized type annotation must error out instead of crashing in
|
|
# VoidType alloca; ast.expr (invalid) errors, ast.AST (valid) compiles.
|
|
# ============================================================
|
|
class Result:
|
|
__slots__ = ('elem_type_node', 'count_node', 'is_pointer')
|
|
|
|
def __init__(self, elem: ast.AST, count: ast.AST*, flag: bool) -> None:
|
|
self.elem_type_node: ast.AST = elem
|
|
self.count_node: ast.AST* = count
|
|
self.is_pointer: bool = flag
|
|
|
|
def main() -> int:
|
|
return 0
|