checkers

package
v0.0.0-...-c6dfda3 Latest Latest
Warning

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

Go to latest
Published: Apr 9, 2022 License: BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterCallChecker

func RegisterCallChecker(doc Doc, constructor func() CallChecker)

func RegisterFuncChecker

func RegisterFuncChecker(doc Doc, constructor func() FuncChecker)

func RegisterStmtChecker

func RegisterStmtChecker(doc Doc, constructor func() StmtChecker)

Types

type CallChecker

type CallChecker interface {
	CheckCall(ctx *lint.Context, call *ast.CallExpr) error
}

type Doc

type Doc struct {
	Name  string
	Score int

	OptLevel int

	NeedsProfile bool
}

type FuncChecker

type FuncChecker interface {
	CheckFunc(ctx *lint.Context, body *ast.BlockStmt) error
}

type PackageChecker

type PackageChecker interface {
	CheckPackage(ctx *lint.SharedContext, files []lint.SourceFile) error
}

func Create

func Create(filter func(doc Doc) bool) []PackageChecker

type StmtChecker

type StmtChecker interface {
	CheckStmt(ctx *lint.Context, stmt ast.Stmt) error
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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