From: Brad Fitzpatrick Date: Sun, 5 Jul 2015 17:00:14 +0000 (-0700) Subject: doc: add section about standard library to the FAQ X-Git-Tag: go1.5beta2~91 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=8a28242b5f7c20d0e215ea9996fa3c5171ee14fb;p=gostls13.git doc: add section about standard library to the FAQ Fixes #10246 Change-Id: Ifa698232a09e1c37f3a9340ffdc1f2650c06fe4c Reviewed-on: https://go-review.googlesource.com/11900 Reviewed-by: Rob Pike --- diff --git a/doc/go_faq.html b/doc/go_faq.html index 78a96568bc..f61e24a662 100644 --- a/doc/go_faq.html +++ b/doc/go_faq.html @@ -1591,6 +1591,51 @@ test cases. The standard Go library is full of illustrative examples, such as in the formatting tests for the fmt package.

+

+Why isn't X in the standard library?

+ +

+The standard library's purpose is to support the runtime, connect to +the operating system, and provide key functionality that many Go +programs require, such as formatted I/O and networking. +It also contains elements important for web programming, including +cryptography and support for standards like HTTP, JSON, and XML. +

+ +

+There is no clear criterion that defines what is included because for +a long time, this was the only Go library. +There are criteria that define what gets added today, however. +

+ +

+New additions to the standard library are rare and the bar for +inclusion is high. +Code included in the standard library bears a large ongoing maintenance cost +(often borne by those other than the original author), +is subject to the Go 1 compatibility promise +(blocking fixes to any flaws in the API), +and is subject to the Go +release schedule, +preventing bug fixes from being available to users quickly. +

+ +

+Most new code should live outside of the standard library and be accessible +via the go tool's +go get command. +Such code can have its own maintainers, release cycle, +and compatibility guarantees. +Users can find packages and read their documentation at +godoc.org. +

+ +

+Although there are pieces in the standard library that don't really belong, +such as log/syslog, we continue to maintain everything in the +library because of the Go 1 compatibility promise. +But we encourage most new code to live elsewhere. +

Implementation