[rustjava-cp-tag-switch-passthrough-mutation-detectable] test(classfile): 태그 pass-through 개악을 end-to-end 로 「잡히게」 한다 - #49
Merged
Conversation
…le): 태그 pass-through 개악을 end-to-end 로 «잡히게» 한다
「알 수 없는 상수풀 태그를 거부한다」는 테스트가 그 가지를 개악해도 green 이었다.
- 근인(판별 실험): 옛 픽스처가 Hello.class 의 «참조되는» Methodref 슬롯을 덮어
파일이 여러 경로로 동시에 깨졌고, ClassFileError 가 문면을 평탄화해
「태그가 미지라 거부」와 「클래스가 무너져 거부」를 구별하지 못했다.
★desync 가설은 기각했다 — 4바이트를 정확히 소비하는 개악도 green 이었다.
- 처방: 단언을 조이는 것이 아니라 입력이 그 가지에 «유일한 결함»으로 도달하게 했다.
test-data/cp/UnreferencedTag{13,14,19}.class =
참조되지 않고 · 페이로드 0 · 상수풀 맨 끝인 엔트리 하나만 미지 태그.
- 전/후: 같은 개악에 대해 전 ok → 후 red(문면 must be rejected: "" = 클래스가 실행됨).
다른 가지(태그 16) 개악 → 6 테스트 red ⇒ 스위트는 여전히 switch 전체를 지킨다.
★제품 코드 변경 0 — 개악은 실증용 임시이고 전부 되돌렸다.
added 2 commits
September 16, 2026 18:05
… 게이트③ 착지 기록 동봉 (PR #49 · --merge)
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.
결함 — ★테스트가 자기가 지킨다고 말하는 것을 지키지 않았다
parse_tagged의 pass-through 가지를 거부 → 통과로 개악:⇒
test_unsupported_constant_pool_tag_raises_class_format_error는 ★여전히 «ok».스위트 전체에서 그 개악을 문 것은
constant_pool::tests::tags_outside_the_accepted_set_are_still_rejected1건뿐 — ★end-to-end 층에는 없었다.★근인 — 추측이 아니라 «판별 실험»으로 좁혔다
옛 테스트는
Hello.class상수풀 1번의 태그 바이트를 덮는데, 그 슬롯은 ★코드가invokespecial로 참조하는 Methodref 다⇒ 덮는 순간 파일이 여러 경로로 동시에 깨진다. 그리고
ClassFileError가 모든 파싱 실패를★**「Invalid class file」로 평탄화하므로(그 테스트 파일이 스스로 적어 둔 한계) 단언이
★「태그가 미지라 거부」와 「클래스가 무너져 거부」를 구별하지 못한다.**
★★경쟁 가설(바이트 어긋남)은 «실험으로 기각»했다 —
Methodref와 같은 4바이트를 정확히 소비하는 개악으로도 여전히 green.처방 — ★단언 조이기가 «아니다»
문면이 평탄해 조일 것이 없다. ⇒ ★입력이 그 가지에 «유일한 결함»으로 도달하게 했다.
test-data/cp/UnreferencedTag{13,14,19}.class(생성기test-data/src/cp/make_cp_fixtures.py신규):access_flags에 정확히 서 있다★세 성질이 «전부» 값한다: 뒤 둘이 없으면 개악이 «다르게 깨진» 파일을 만들어 또 green 이 된다.
전/후 — 같은 개악, 다른 결과
must be rejected: ""(★빈 출력 = 클래스가 «성공적으로 실행»됐다)cargo test --all568 / 0 failed / 1 ignored — ★수 불변(테스트 1개 «치환») ⇒ ★수가 아니라 전/후 개악 쌍이 증거다.★제품 코드 변경 «0»
개악은 실증용 임시이고 전부 되돌렸다 —
git diff --cached에 제품 크레이트 0건 ·복원된
constant_pool.rssha393e0594d7eb647e일치.계약 2 — 흔들림 점검
옛 픽스처(
BadTag*)를 쓰던 다른 테스트 0건(전수) ·hello_class()·fixture()헬퍼는 여전히 4·5회 쓰여 고아 0 ·새 단언은 ★오탐이 늘지 않는다(픽스처가 결함 하나만 갖도록 지어져 흔들릴 표면이 좁다) · 픽스처 재생성 멱등.
DoD 7줄 전건 rc=0.
채택 제안
2026-09-16-ldc-tags-15-16-17#p1(worklog jsonadoptedProposals기록)