From 915054495f3e49fb145b097f8bdea8b01880b16c Mon Sep 17 00:00:00 2001 From: TermiNexus Date: Wed, 19 Aug 2026 05:26:26 +0800 Subject: [PATCH] =?UTF-8?q?fix(ast):=20=E8=A1=A5=E9=BD=90=20exprs=20?= =?UTF-8?q?=E5=AD=97=E6=AE=B5=E8=AE=BF=E9=97=AE=E8=BE=85=E5=8A=A9=E5=87=BD?= =?UTF-8?q?=E6=95=B0=20re-export?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 5cda173 只补了 attribute_get_attr,TypeGen 还以 ast. 调用 attribute_get_value/name_get_id/constant_get_str_val/binop_get_left/ binop_get_right(均定义在 ast.exprs)→ 同样触发跨模块返回类型解析 fail-fast。一次性全部补入 from .exprs import 导出列表。 --- includes/ast/__init__.vp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/includes/ast/__init__.vp b/includes/ast/__init__.vp index b82bdca..b87234a 100644 --- a/includes/ast/__init__.vp +++ b/includes/ast/__init__.vp @@ -37,10 +37,12 @@ from .exprs import ( Constant, NamedExpr, Attribute, Subscript, Starred, Name, List, Tuple, Slice, Call, Compare, OpNode, - # 属性访问辅助函数(TPV TypeGen 以 ast.attribute_get_attr 调用; - # 未 re-export 时跨模块函数返回类型解析在 ast 包 text.ll 找不到 - # 定义(定义在 ast.exprs)→ fail-fast "返回类型无法精确获取") - attribute_get_attr, + # 字段访问辅助函数(TPV TypeGen 以 ast. 跨模块调用;未 re-export + # 时跨模块函数返回类型解析在 ast 包 text.ll 找不到定义(定义在 ast.exprs) + # → fail-fast "返回类型无法精确获取",如 attribute_get_attr/attribute_get_value) + name_get_id, constant_get_str_val, + binop_get_left, binop_get_right, + attribute_get_attr, attribute_get_value, ) # Auxiliary Nodes from .astaux import (