[sergo] Sergo Report: New-Linter Audit (typeassertionnil) - 2026-10-02 #64906
Closed
Replies: 1 comment
|
This discussion has been marked as outdated by Sergo - Serena Go Expert. A newer discussion is available at Discussion #65228. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Overview
Run §36961902897 - strategy: new-linter audit (typeassertionnil, 75th registered analyzer) + reconcile refresh. Registry grew 74->75 since yesterday own run, giving a clean 50/50 split: cached-proven reconcile methodology on one side, fresh exploration of the newly-added linter on the other.
Key Findings
1 issue filed (
sg84a1): typeassertionnil (pkg/linters/typeassertionnil/typeassertionnil.go:62-75) gates pointer-type detection on AST shape (typeAssert.Type.(*ast.StarExpr)) before ever consultingpass.TypesInfo. Two valid pointer-assertion shapes escape as a result:type P = *T; v.(P)) - go/types resolves these transparently to*types.Pointer, but the syntactic gate returns before TypesInfo is reached.v.((*T))) - legal per the assertion grammar, buttypeAssert.Typebecomes an*ast.ParenExprand the same early-return skips it.This is the first time the established paren_unwrap_gap pattern class has shown up on the asserted-Type position rather than a value expression - it has now recurred independently in consecutive new-linter audits (closeerrorunchecked at R82, typeassertionnil here). Confirmed clean: the sibling linter
typeassertionokdiscardedalready covers thex, _ := v.(T)discarded-ok case regardless of pointer-ness, so that is correctly out of scope here, not a gap.Reconcile
Ran a fresh
gh apiquery againststate=open&labels=sergodirectly (per last run lesson, rather than trusting a predicted list) - 16 opens, all matching memory expectations exactly. Both of yesterday refiles (sg83a1/sg83a2, #64680/#64681) confirmed landed-as-filed and still open. Zero new reverse-phantom flips this run - first clean zero-flip reconcile since R73.Metrics
Next-Run Focus
sg84a1landed.paren_unwrap_gapcheck (bare*ast.BasicLit/*ast.Ident/*ast.CallExpr/*ast.StarExprassertions withoutUnwrapParenExpr) to any new linter before anything else, since it keeps recurring independently.closeerrorunchecked(74th) ortypeassertionnil(75th) land incgo.ymlLINTER_FLAGS.All reactions