Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unicode/utf8: document specification #31590

Open
dsnet opened this issue Apr 20, 2019 · 1 comment

Comments

Projects
None yet
4 participants
@dsnet
Copy link
Member

commented Apr 20, 2019

The utf8 package merely documents that it "supports text encoded in UTF-8", but doesn't point to any external sources for what "UTF-8" exactly is. I'm not an expert in this area, but my understanding is that UTF-8 is formally defined in RFC 3629. Is that true?

Furthermore, does the Valid function implement validation for merely the syntax of UTF-8 encoding (section 4) or a validation of the "definition" of UTF-8 (section 3)? The code seems to suggest that it is the later. The godoc does not make this clear to me and probably should be documented.

@ALTree ALTree added this to the Go1.13 milestone Apr 21, 2019

@rsc

This comment has been minimized.

Copy link
Contributor

commented May 1, 2019

I'm sure we can find the right chapter of the Unicode spec and link to that (unicode.org).
https://www.unicode.org/versions/Unicode12.0.0/UnicodeStandard-12.0.pdf#page=65

@rsc rsc added the NeedsFix label May 1, 2019

@gopherbot gopherbot removed the NeedsDecision label May 1, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.