Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
GitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
fmt: Documentation for *scanf should mention whether short reads are errors. #8708
The comment for fmt.Fscan says: It returns the number of items successfully scanned. If that is less than the number of arguments, err will report why. But fmt.Fscanf only says: It returns the number of items successfully parsed. From reading the source, it seems that the formatted variants are also intended to return a non-nil error for short scans: http://play.golang.org/p/aS0XEsQLWp If so, the documentation should be made consistent to reflect this.