Standard library / bufio
bufio.ErrTooLong
Signals a scanner token too large for configured buffer limit. Expected stdout: 'true\n'.
Formal Syntax & Structure
go syntaxgo
var ErrTooLong errorWorking Example
Example Snippetgo
package main
import ( "bufio" "fmt" "strings")
func main() { s := bufio.NewScanner(strings.NewReader(strings.Repeat("a", 100))) s.Buffer(make([]byte, 8), 16) s.Scan() fmt.Println(s.Err() == bufio.ErrTooLong)}