srcerrors

package
v1.41.7 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2024 License: MPL-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CUEEvaluationFailed

func CUEEvaluationFailed(err error, pathPrefix string) error

func GenericError added in v1.14.5

func GenericError(pos token.Position, msg string, fileReaders ...paths.FileReader) *errinsrc.ErrInSrc

GenericError is a place holder for errors reported through perr.Add or perr.Addf

func GenericGoCompilerError

func GenericGoCompilerError(fileName string, lineNumber int, column int, error string, fileReaders ...paths.FileReader) error

GenericGoCompilerError reports an error was that was reported from the Go compiler. It should not be returned by any errors caused by Encore's own compiler as they should have specific errors listed below.

func GenericGoPackageError added in v1.14.5

func GenericGoPackageError(err packages.Error, fileReaders ...paths.FileReader) *errinsrc.ErrInSrc

GenericGoPackageError reports an error was that was reported from the Go package loader. It should not be returned by any errors caused by Encore's own parser as they should have specific errors listed below

func GenericGoParserError

func GenericGoParserError(err *scanner.Error, fileReaders ...paths.FileReader) *errinsrc.ErrInSrc

GenericGoParserError reports an error was that was reported from the Go parser. It should not be returned by any errors caused by Encore's own parser as they should have specific errors listed below

func ResourceNameReserved added in v1.11.0

func ResourceNameReserved(fileset *token.FileSet, node ast.Node, resourceType string, paramName string, name, reservedPrefix string, isSnakeCase bool, fileReaders ...paths.FileReader) error

func StandardLibraryError added in v1.14.5

func StandardLibraryError(err error) *errinsrc.ErrInSrc

StandardLibraryError is an error that is not caused by Encore, but is returned by a standard library function. We wrap it in an ErrInSrc so that we can still possibly provide a source location.

func UnableToAddOrphanedCUEFiles

func UnableToAddOrphanedCUEFiles(err error, pathPrefix string) error

func UnableToLoadCUEInstances

func UnableToLoadCUEInstances(err error, pathPrefix string) error

func UnhandledPanic

func UnhandledPanic(recovered any) error

UnhandledPanic is an error we use to wrap a panic that was not handled It should ideally never be seen by users, but if it is, it means we have a bug within Encore which needs fixing.

Types

This section is empty.

Jump to

Keyboard shortcuts

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