linterror

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2022 License: Apache-2.0 Imports: 8 Imported by: 2 modules, 2 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

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CalcLintLine

func CalcLintLine(source, scope []byte, goal func(line []byte) bool) (line string, num int)

CalcLintLine calculates the lint error line number of the SQL script

Types

type LintError

type LintError struct {
	ScriptName string // 脚本名称
	Stmt       string // SQL 语句
	Lint       string // lint 提示
	Line       string // lint 提示所在的行内容
	LintNo     int    // lint 提示所在行行号
}

func New

func New(script script.Script, stmt string, lint string, getLine func(line []byte) bool) LintError

func (LintError) Error

func (e LintError) Error() string

func (LintError) StmtName

func (e LintError) StmtName() string

Jump to

Keyboard shortcuts

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