cmd/compile: Type.obj appears to be nil most (all?) of the time · Issue #81257 · golang/go · GitHub
Skip to content You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert cmd/compile: Type.obj appears to be nil most (all?) of the time #81257 New issue Copy link New issue Copy link Open Open cmd/compile: Type.obj appears to be nil most (all?) of the time #81257 Copy link Assignees Labels NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. compiler/runtime Issues related to the Go compiler and/or runtime. Issues related to the Go compiler and/or runtime. Milestone Go1.28 Description griesemer opened on Aug 31, 2026 Issue body actions The compiler internal error (now circumvented) reported in #81241 is due to a missing (cmd/compile/internal/types) type Object ( Type.obj ) of a struct.
With a nil obj field, the type position is unknown which lead to an internal compiler error in that case. The Type.obj field should be set at some point, perhaps after TFORW types are resolved (which would still be too late for the above case). It's also not clear where a type's position should be stored in the type is unnamed; presumably no Object exists in that case. A cursory investigation seemed to imply that Type.obj is mostly (always?) nil.
Should investigate and resolve as this may be the cause for possibly other internal compiler errors. Activity griesemer added this to the Go1.28 milestone on Aug 31, 2026 griesemer assigned griesemer and mrkfrmn on Aug 31, 2026 griesemer added NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. on Aug 31, 2026 gopherbot added compiler/runtime Issues related to the Go compiler and/or runtime.
Issues related to the Go compiler and/or runtime. on Aug 31, 2026 github-project-automation added this to Go Compiler / Runtime / Command on Aug 31, 2026 griesemer commented on Aug 31, 2026 griesemer on Aug 31, 2026 Contributor Author More actions See also #81241 (comment) . cherrymui moved this to Todo in Go Compiler / Runtime / Command on Sep 15, 2026 Sign up for free to join this conversation on GitHub. Already have an account?
Sign in to comment Metadata Metadata Assignees griesemer mrkfrmn Labels NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. compiler/runtime Issues related to the Go compiler and/or runtime. Issues related to the Go compiler and/or runtime. Type No type Projects Go Compiler / Runtime / Command Status Todo Show more project fields Milestone Go1.28 No due date Relationships None yet Development No branches or pull requests Issue actions You can’t perform that action at this time.