erorr

package module
v0.0.0-...-8cbde6d Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2024 License: MIT Imports: 2 Imported by: 0

README

go-erorr

Package erorr implements tools to create and manipulate errors, for the Go programming language.

(This package used to be called "fck".)

Documention

Online documentation, which includes examples, can be found at: http://godoc.org/github.com/reiver/go-erorr

GoDoc

Creating Errors

There are two ways to create errors —

With erorr.Error:

	const err error = erorr.Error("internal-error")

NOTICE THAT THAT ERROR IS A const RATHER THAN A var.

Errors creating using erorr.Error can be a Go const.

And with erorr.Errorf:

	var err error = erorr.Errorf("bad value for id %q", id)

Import

To import package erorr use import code like the follownig:

import "github.com/reiver/go-erorr"

Installation

To install package erorr do the following:

GOPROXY=direct go get https://github.com/reiver/go-erorr

Author

Package erorr was written by Charles Iliya Krempeaux

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Errorf

func Errorf(format string, a ...interface{}) error

func Is

func Is(err, target error) bool

Types

type Error

type Error string

func (Error) Error

func (receiver Error) Error() string

Jump to

Keyboard shortcuts

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