Don Newton | 379ae25 | 2019-04-01 12:17:06 -0400 | [diff] [blame^] | 1 | package stringprep |
2 | |||||
3 | import "fmt" | ||||
4 | |||||
5 | // Error describes problems encountered during stringprep, including what rune | ||||
6 | // was problematic. | ||||
7 | type Error struct { | ||||
8 | Msg string | ||||
9 | Rune rune | ||||
10 | } | ||||
11 | |||||
12 | func (e Error) Error() string { | ||||
13 | return fmt.Sprintf("%s (rune: '\\u%04x')", e.Msg, e.Rune) | ||||
14 | } |