についてボタンはいくつかのヒントを与える:
遊び場は、いくつかの例外を除いて、標準ライブラリのほとんどを使用することができます。 標準ライブラリの標準ライブラリによって
パッケージはStandard libraryセクションの下で、Packagesページにリストされて、意図されています。 Otherセクションに記載されているパッケージは、あなたが試したものです - パッケージgolang.org/x/exp/ebnf
は、その他のカテゴリの下にリストされている実験的で推奨されていないパッケージの下にあります。
A-読まなければならないリンクあなたは遊び場の実装についての詳細をお知りになりたい場合:ここで
The Go Blog: Inside the Go Playground
は、彼らは、少なくともインポートすることができます表示するには、すべての標準的なライブラリパッケージをインポートするための徹底的な遊び場のテストですしかし、それはすべてから(または何でも)それらを合理的に使用できることを意味するものではありません。コンパイルエラーを与える標準ライブラリの唯一のパッケージはruntime/cgo
です。ビルド可能なGoソースファイルのない「パッケージ」は、少なくとも1つのビルド可能なGoソースファイルが含まれていない場合はnot a packageなので、明確な理由から含まれていません。
こちらは自分で試してみるPlayground Linkです。
package main
import (
_ "archive/tar"
_ "archive/zip"
_ "bufio"
_ "bytes"
_ "compress/bzip2"
_ "compress/flate"
_ "compress/gzip"
_ "compress/lzw"
_ "compress/zlib"
_ "container/heap"
_ "container/list"
_ "container/ring"
_ "crypto"
_ "crypto/aes"
_ "crypto/cipher"
_ "crypto/des"
_ "crypto/dsa"
_ "crypto/ecdsa"
_ "crypto/elliptic"
_ "crypto/hmac"
_ "crypto/md5"
_ "crypto/rand"
_ "crypto/rc4"
_ "crypto/rsa"
_ "crypto/sha1"
_ "crypto/sha256"
_ "crypto/sha512"
_ "crypto/subtle"
_ "crypto/tls"
_ "crypto/x509"
_ "crypto/x509/pkix"
_ "database/sql"
_ "database/sql/driver"
_ "debug/dwarf"
_ "debug/elf"
_ "debug/gosym"
_ "debug/macho"
_ "debug/pe"
_ "debug/plan9obj"
_ "encoding"
_ "encoding/ascii85"
_ "encoding/asn1"
_ "encoding/base32"
_ "encoding/base64"
_ "encoding/binary"
_ "encoding/csv"
_ "encoding/gob"
_ "encoding/hex"
_ "encoding/json"
_ "encoding/pem"
_ "encoding/xml"
_ "errors"
_ "expvar"
_ "flag"
_ "fmt"
_ "go/ast"
_ "go/build"
_ "go/constant"
_ "go/doc"
_ "go/format"
_ "go/importer"
_ "go/parser"
_ "go/printer"
_ "go/scanner"
_ "go/token"
_ "go/types"
_ "hash"
_ "hash/adler32"
_ "hash/crc32"
_ "hash/crc64"
_ "hash/fnv"
_ "html"
_ "html/template"
_ "image"
_ "image/color"
_ "image/color/palette"
_ "image/draw"
_ "image/gif"
_ "image/jpeg"
_ "image/png"
_ "index/suffixarray"
_ "io"
_ "io/ioutil"
_ "log"
_ "log/syslog"
_ "math"
_ "math/big"
_ "math/cmplx"
_ "math/rand"
_ "mime"
_ "mime/multipart"
_ "mime/quotedprintable"
_ "net"
_ "net/http"
_ "net/http/cgi"
_ "net/http/cookiejar"
_ "net/http/fcgi"
_ "net/http/httptest"
_ "net/http/httputil"
_ "net/http/pprof"
_ "net/mail"
_ "net/rpc"
_ "net/rpc/jsonrpc"
_ "net/smtp"
_ "net/textproto"
_ "net/url"
_ "os"
_ "os/exec"
_ "os/signal"
_ "os/user"
_ "path"
_ "path/filepath"
_ "reflect"
_ "regexp"
_ "regexp/syntax"
_ "runtime"
// _ "runtime/cgo" // ERROR: missing Go type information
// for global symbol: .dynsym size 60
_ "runtime/debug"
_ "runtime/pprof"
_ "runtime/race"
_ "runtime/trace"
_ "sort"
_ "strconv"
_ "strings"
_ "sync"
_ "sync/atomic"
_ "syscall"
_ "testing"
_ "testing/iotest"
_ "testing/quick"
_ "text/scanner"
_ "text/tabwriter"
_ "text/template"
_ "text/template/parse"
_ "time"
_ "unicode"
_ "unicode/utf16"
_ "unicode/utf8"
_ "unsafe"
)
func main() {
println("ok")
}
"プレイグラウンドでは、いくつかの例外を除き、ほとんどの標準ライブラリを使用できます。"さて、stdlibよりも小さく;) –
BTWありがとうございました。もちろん私はそのことを読むだろう。私は誰もが言っていることを言います。 「最も」とは言わないか、標準ライブラリにないものは使用できません。それに関するブログ記事は、標準的なライブラリの振る舞いが正常と異なるいくつかの領域を指摘しています。私は答えに記載されているテストに基づいて、より完全なリストに感謝します。 – dlamblin