This commit is contained in:
parent
9b51680af5
commit
c2b8db238e
24 changed files with 624 additions and 232 deletions
13
src/errors/InvalidCharacter.go
Normal file
13
src/errors/InvalidCharacter.go
Normal file
|
@ -0,0 +1,13 @@
|
|||
package errors
|
||||
|
||||
import "fmt"
|
||||
|
||||
// InvalidCharacter is created when an invalid character appears.
|
||||
type InvalidCharacter struct {
|
||||
Character string
|
||||
}
|
||||
|
||||
// Error implements the error interface.
|
||||
func (err *InvalidCharacter) Error() string {
|
||||
return fmt.Sprintf("Invalid character '%s'", err.Character)
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue