修 id 解析

This commit is contained in:
2026-08-01 14:15:13 +02:00
parent 130f8b4c1d
commit 656fab349d
8 changed files with 293 additions and 13 deletions
+7 -1
View File
@@ -300,7 +300,13 @@ function collectAttributes(node, out = []) {
doc: docOf(attr),
kind: desc?.kind ?? "unknown",
type: desc?.name ?? null,
refType: normalizeTypeName(desc?.refType) ?? null,
// xas:refType may be declared on the attribute itself (e.g.
// <xs:attribute name="id" type="Poid" xas:refType="ModuleData" />) or
// on its simple type. The attribute-level declaration wins.
refType:
normalizeTypeName(attr["@_refType"]) ??
normalizeTypeName(desc?.refType) ??
null,
enumValues: desc?.enumValues ?? inlineEnum ?? [],
allowsDefine: desc?.allowsDefine ?? false,
isRef: desc?.isRef ?? false,