prodfiles

package
v0.9.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 24, 2026 License: MIT Imports: 3 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package prodfiles 是各检查器共享的「生产代码文件」过滤:-tests 开关 关闭(默认)时只检查非 _test.go 文件。

为什么默认跳过测试文件:这些检查器约束的是线上形态(JSON 面、ctx 流向、 金额类型),测试夹具低一档——float64 近似断言半合法,fake 持 ctx 也只是 风味问题;而且 domain-ci.yml 经 @main 被全部存量域仓库共享,规则升级 不该让它们的测试文件一夜变红。要连测试一起查就显式 -xxx.tests=true。

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Files

func Files(fset *token.FileSet, files []*ast.File, skipTests bool) []*ast.File

Files 返回待检查文件:skipTests 为 true 时剔除 _test.go。 返回新切片,不动传入切片的底层数组(那是 pass.Files 的)。

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL