Skip to content

fix panic for nil value method wrappers#1921

Draft
cpunion wants to merge 1 commit into
xgo-dev:mainfrom
cpunion:codex/goroot-fixedbugs-panicwrap
Draft

fix panic for nil value method wrappers#1921
cpunion wants to merge 1 commit into
xgo-dev:mainfrom
cpunion:codex/goroot-fixedbugs-panicwrap

Conversation

@cpunion
Copy link
Copy Markdown
Collaborator

@cpunion cpunion commented May 24, 2026

Fixes the remaining fixedbugs/issue19040.go panic text mismatch by implementing the compiler-generated wrapnilchk path for value-method wrappers invoked through nil pointers.

Coverage:

  • Adds test/go coverage for nil *T assigned to an interface and calling a value receiver method.
  • Removes the fixedbugs/issue19040.go xfail entries for Darwin and Linux Go 1.24/1.25/1.26.
  • Refreshes affected LITTEST IR goldens for generated wrapper nil checks.

Local validation:

  • go test ./cl ./ssa -count=1
  • go test ./test/go -run TestValueMethodWrapperNilPointerPanic -count=1
  • go run ./cmd/llgo run "$(go env GOROOT)/test/fixedbugs/issue19040.go"
  • go test ./test/goroot -run TestGoRootRunCases -count=1 -timeout 30m -args -goroot "$(go env GOROOT)" -case "fixedbugs/issue19040.go" -xfail -progress 30s

@codecov-commenter
Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants