Repository navigation
docs(批8 (甲) 刀4): 路线图 v10——§8 S1 改判扩到两侧同批 + §7.3 连锁①裁定(b)落纸(规模6→≥60留痕) + §7.1 ABI/合成面注 + 协作面纪律(按 #160 术语重做) - #154
Merged
Merged
Conversation
…ched_go 调用点=0 · Chan/Future 同批 · §7.3 连锁①裁定(b) ≥60 · S1 已实施+CI红归因
dslsdzc
force-pushed
the
feature/b8-e1-blade4-v10
branch
from
September 23, 2026 04:28
81fbffb to
a8c9013
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
本 PR = 路线图 v10(纸面,零代码、零行为)
⚠ 重做说明(2026-09-23):本草稿原以 2026-09-19 的
develop(38e6c992)为基线,与后来的术语批(#160,124 文件 / 1944 行 1:1)冲突——原样合入会把该批的术语替换倒回去。故按当前develop(7cf724f6)重做:内容逐条保留,术语按 #160 的对照转换(口径→约定·台账→清单·两向钉子→正反两条断言·反向钉→反向断言·哨兵族→标记值族)。逐行核对:新档与旧 v10 的差异 = 36 增 / 36 删,逐行只有词不同(没有内容丢失或新增);改动规模仍 = +53 / −18(含刻意保留的旧文,见下)。
一、§8
S1约定修正(lead 裁):一处 → 两侧同批checker.cr:2966alloc_type(TYP_PTR, inner, 0)→alloc_type(TYP_REF, inner, is_mut)ir_gen.cr:1858(v9 原文未列)new_ir_var("ref", alloc_type(TYP_PTR, pti, 0))→alloc_type(TYP_REF, pti, ast_int_val(node))为什么:
checker只决定语义视图;region_check/provenance_verify/ptr_analysis/ 后端读的是irv_type()。只改一处 ⇒ 三道安全门看到的仍是TYP_PTR⇒ S6 的 (a) 扩法对着「永不出现的 kind」生效 = 静默空转——正是「正向断言必须验到「检查真的触发」」所防的形态,而它出现在本计划自己的 S1 原文里。并附 S1 实测(✅ 本体全过):
--dump-types现在kind 3(TYP_REF) 且extra 0与extra 1两行并存(&x与&mut x可区分)· 清单 2 → 0 ·check src/compilerrc=0 / 0 诊断 · 自举 SUCCESS · 行为影响面恰 1 档 1 条(ptr_ref_first的 TF07 = §5.3 已确证的 S2 靶心)。并记 CI 红及其归因:
selfhost-tests⇒selftest-types413/415,恰 2 例(ops.infer_ptr_add_int/ops.infer_ptr_diff)——逐行读过,落在checker.cr:2903/2906/2910的算术门(仍只认TYP_PTR)= S3 本体 ⇒ S1 与 S3 是同一刀的先后半个。并记一处待裁:
ir_gen.cr:1826的&arr[i](IR_ADDR_INDEX)仍是TYP_PTR⇒ 现态两种取址形式类型不同;实施时未擅自扩(裁定原文只写&x)⇒ 待裁 (甲) 本批一并改 / (乙) 独立条目。二、§7.3 连锁 ① 裁定落纸:候选 (b)
@ptr_of/@str_of改到Buf侧 ⇒string退回真字符串(彻底)。interp.cr22 ·cli.cr23 ·parser.cr7 ·ld.cr6 ·checker.cr1 ·test1,其中三档是生产代码)⇒ 明写「原写 6 处是低估」。79e0395c那 6 处须在新语义下重做;保留当事人那句「当时按 2(a) 现行契约做,属当时正确」(它把「当时的正确」与「现在的过时」分开)。string全局是裸缓冲 ⇒ 「拆string」在自源里的主战场是globals.cr的表指针 ⇒ 会动编译器自身 ⇒ 牵连.ccr/ canary 面(与重锁同批)。三、§7.1 两条加注(
plan-optdex侦察)——「改」的动作不在调用点goroutine.cr::g_freert.s汇编调用)sched.cr::sched_goir_gen合成发射,名字 intern 后发射)⇒ 不写清,实施者会去找根本不存在的调用点。
新增小节:
Chan<T>与Future<T>必须同批、同一组调用点——chan_recv的 12 个调用点里 5 个来自chan_make、7 个来自go f(x)⇒ 先拆一半 ⇒ 另一半悬空 ⇒ 排期上是两步不是一步。四、§8 头注补协作面纪律(lead 那半)
未动:
checker.cr行为(S1 在 #153)·ld.cr· 冻结链 ·test_pointer_safety.py:173·ptr_arith.cr。