@ttsc/win32-arm64 0.33.0 → 0.34.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/go/VERSION +2 -2
- package/bin/go/bin/go.exe +0 -0
- package/bin/go/bin/gofmt.exe +0 -0
- package/bin/go/lib/time/update.bash +2 -2
- package/bin/go/lib/time/zoneinfo.zip +0 -0
- package/bin/go/pkg/include/asm_ppc64x.h +0 -16
- package/bin/go/pkg/tool/windows_arm64/asm.exe +0 -0
- package/bin/go/pkg/tool/windows_arm64/cgo.exe +0 -0
- package/bin/go/pkg/tool/windows_arm64/compile.exe +0 -0
- package/bin/go/pkg/tool/windows_arm64/cover.exe +0 -0
- package/bin/go/pkg/tool/windows_arm64/fix.exe +0 -0
- package/bin/go/pkg/tool/windows_arm64/link.exe +0 -0
- package/bin/go/pkg/tool/windows_arm64/preprofile.exe +0 -0
- package/bin/go/pkg/tool/windows_arm64/vet.exe +0 -0
- package/bin/go/src/archive/tar/reader.go +2 -1
- package/bin/go/src/archive/zip/reader.go +5 -29
- package/bin/go/src/archive/zip/struct.go +5 -6
- package/bin/go/src/archive/zip/writer.go +120 -60
- package/bin/go/src/bufio/bufio.go +1 -1
- package/bin/go/src/bytes/buffer.go +3 -3
- package/bin/go/src/bytes/bytes.go +45 -25
- package/bin/go/src/compress/flate/deflate.go +512 -363
- package/bin/go/src/compress/flate/deflatefast.go +156 -262
- package/bin/go/src/compress/flate/dict_decoder.go +1 -4
- package/bin/go/src/compress/flate/huffman_bit_writer.go +673 -250
- package/bin/go/src/compress/flate/huffman_code.go +164 -92
- package/bin/go/src/compress/flate/level1.go +195 -0
- package/bin/go/src/compress/flate/level2.go +190 -0
- package/bin/go/src/compress/flate/level3.go +228 -0
- package/bin/go/src/compress/flate/level4.go +200 -0
- package/bin/go/src/compress/flate/level5.go +287 -0
- package/bin/go/src/compress/flate/level6.go +297 -0
- package/bin/go/src/compress/flate/load_store.go +43 -0
- package/bin/go/src/compress/flate/regmask_amd64.go +9 -0
- package/bin/go/src/compress/flate/regmask_other.go +11 -0
- package/bin/go/src/compress/flate/token.go +238 -26
- package/bin/go/src/compress/gzip/gzip.go +8 -0
- package/bin/go/src/compress/zlib/writer.go +12 -0
- package/bin/go/src/context/context.go +6 -5
- package/bin/go/src/crypto/cipher/gcm.go +0 -4
- package/bin/go/src/crypto/crypto.go +27 -4
- package/bin/go/src/crypto/des/const.go +1 -1
- package/bin/go/src/crypto/ecdsa/ecdsa.go +21 -4
- package/bin/go/src/crypto/ed25519/ed25519.go +13 -0
- package/bin/go/src/crypto/internal/boring/aes.go +2 -3
- package/bin/go/src/crypto/internal/cryptotest/aead.go +53 -0
- package/bin/go/src/crypto/internal/cryptotest/boundary.go +34 -0
- package/bin/go/src/crypto/internal/cryptotest/boundary_compat.go +16 -0
- package/bin/go/src/crypto/internal/cryptotest/fetchmodule.go +9 -3
- package/bin/go/src/crypto/internal/cryptotest/fips140.go +62 -3
- package/bin/go/src/crypto/internal/cryptotest/hash.go +14 -0
- package/bin/go/src/crypto/internal/cryptotest/wycheproof/_schema/go.mod +19 -0
- package/bin/go/src/crypto/internal/cryptotest/wycheproof/_schema/go.sum +27 -0
- package/bin/go/src/crypto/internal/cryptotest/wycheproof/_schema/schema_gen.go +151 -0
- package/bin/go/src/crypto/internal/cryptotest/wycheproof/schema.go +9792 -0
- package/bin/go/src/crypto/internal/cryptotest/wycheproof/schemaversion.go +11 -0
- package/bin/go/src/crypto/internal/cryptotest/wycheproof/wycheproof.go +165 -0
- package/bin/go/src/crypto/internal/cryptotest/x509limbo/_schema/go.mod +14 -0
- package/bin/go/src/crypto/internal/cryptotest/x509limbo/_schema/go.sum +25 -0
- package/bin/go/src/crypto/internal/cryptotest/x509limbo/_schema/schema_gen.go +125 -0
- package/bin/go/src/crypto/internal/cryptotest/x509limbo/schema.go +591 -0
- package/bin/go/src/crypto/internal/cryptotest/x509limbo/schemaversion.go +14 -0
- package/bin/go/src/crypto/internal/fips140/aes/_asm/ctr/go.mod +1 -1
- package/bin/go/src/crypto/internal/fips140/aes/_asm/standard/go.mod +1 -1
- package/bin/go/src/crypto/internal/fips140/aes/gcm/_asm/gcm/gcm_amd64_asm.go +36 -32
- package/bin/go/src/crypto/internal/fips140/aes/gcm/_asm/gcm/go.mod +5 -5
- package/bin/go/src/crypto/internal/fips140/aes/gcm/_asm/gcm/go.sum +8 -6
- package/bin/go/src/crypto/internal/fips140/aes/gcm/gcm_amd64.s +29 -17
- package/bin/go/src/crypto/internal/fips140/aes/gcm/gcm_arm64.s +73 -72
- package/bin/go/src/crypto/internal/fips140/aes/gcm/ghash.go +140 -124
- package/bin/go/src/crypto/internal/fips140/bigmod/nat.go +18 -0
- package/bin/go/src/crypto/internal/fips140/check/checktest/asm_loong64.s +23 -0
- package/bin/go/src/crypto/internal/fips140/check/checktest/asm_none.go +1 -1
- package/bin/go/src/crypto/internal/fips140/check/checktest/asm_stub.go +1 -1
- package/bin/go/src/crypto/internal/fips140/drbg/rand.go +12 -4
- package/bin/go/src/crypto/internal/fips140/ecdsa/ecdsa.go +17 -10
- package/bin/go/src/crypto/internal/fips140/edwards25519/field/_asm/fe_amd64_asm.go +0 -90
- package/bin/go/src/crypto/internal/fips140/edwards25519/field/fe.go +64 -97
- package/bin/go/src/crypto/internal/fips140/edwards25519/field/fe_amd64.go +0 -5
- package/bin/go/src/crypto/internal/fips140/edwards25519/field/fe_amd64.s +0 -167
- package/bin/go/src/crypto/internal/fips140/edwards25519/field/fe_amd64_noasm.go +0 -2
- package/bin/go/src/crypto/internal/fips140/edwards25519/field/fe_generic.go +57 -1
- package/bin/go/src/crypto/internal/fips140/edwards25519/scalarmult.go +3 -2
- package/bin/go/src/crypto/internal/fips140/mldsa/mldsa.go +31 -25
- package/bin/go/src/crypto/internal/fips140/mldsa/semiexpanded.go +2 -2
- package/bin/go/src/crypto/internal/fips140/nistec/_asm/go.mod +4 -4
- package/bin/go/src/crypto/internal/fips140/nistec/_asm/go.sum +6 -0
- package/bin/go/src/crypto/internal/fips140/nistec/_asm/p256_asm.go +1 -613
- package/bin/go/src/crypto/internal/fips140/nistec/p256.go +2 -2
- package/bin/go/src/crypto/internal/fips140/nistec/p256_asm.go +7 -6
- package/bin/go/src/crypto/internal/fips140/nistec/p256_asm_amd64.s +0 -503
- package/bin/go/src/crypto/internal/fips140/nistec/p256_asm_arm64.s +4 -429
- package/bin/go/src/crypto/internal/fips140/nistec/p256_ordinv.go +511 -47
- package/bin/go/src/crypto/internal/fips140/pbkdf2/pbkdf2.go +1 -1
- package/bin/go/src/crypto/internal/fips140/rsa/keygen.go +48 -46
- package/bin/go/src/crypto/internal/fips140/rsa/largeexponent.go +365 -0
- package/bin/go/src/crypto/internal/fips140/rsa/pkcs1v15.go +27 -0
- package/bin/go/src/crypto/internal/fips140/sha256/_asm/go.mod +1 -1
- package/bin/go/src/crypto/internal/fips140/sha3/_asm/go.mod +1 -1
- package/bin/go/src/crypto/internal/fips140/sha512/_asm/go.mod +1 -1
- package/bin/go/src/crypto/internal/fips140/subtle/constant_time.go +1 -1
- package/bin/go/src/crypto/internal/fips140/subtle/xor_asm.go +1 -1
- package/bin/go/src/crypto/internal/fips140/subtle/xor_riscv64.go +18 -0
- package/bin/go/src/crypto/internal/fips140/subtle/xor_riscv64.s +33 -2
- package/bin/go/src/crypto/internal/fips140deps/cpu/cpu.go +2 -0
- package/bin/go/src/crypto/internal/fips140deps/time/time.go +7 -4
- package/bin/go/src/crypto/internal/fips140only/fips140only.go +0 -7
- package/bin/go/src/crypto/internal/fips140only/random_fips140v1.0.go +17 -0
- package/bin/go/src/crypto/internal/fips140only/random_fips140v1.28.go +16 -0
- package/bin/go/src/crypto/internal/fips140test/acvp_capabilities_fips140v1.28.json +86 -0
- package/bin/go/src/crypto/internal/fips140test/acvp_test_fips140v1.28.config.json +58 -0
- package/bin/go/src/crypto/internal/rand/rand.go +14 -14
- package/bin/go/src/crypto/internal/rand/random_fips140v1.0.go +20 -0
- package/bin/go/src/crypto/internal/rand/random_fips140v1.28.go +19 -0
- package/bin/go/src/crypto/mldsa/mldsa.go +97 -0
- package/bin/go/src/crypto/mldsa/mldsa_fips140v1.0.go +116 -0
- package/bin/go/src/crypto/mldsa/mldsa_fips140v1.26.go +226 -0
- package/bin/go/src/crypto/mlkem/mlkem.go +8 -2
- package/bin/go/src/crypto/rsa/fips.go +26 -8
- package/bin/go/src/crypto/rsa/pkcs1v15.go +2 -2
- package/bin/go/src/crypto/rsa/rsa.go +25 -2
- package/bin/go/src/crypto/sha1/sha1block_decl.go +1 -1
- package/bin/go/src/crypto/sha1/sha1block_generic.go +1 -1
- package/bin/go/src/crypto/sha1/sha1block_loong64.s +24 -8
- package/bin/go/src/crypto/sha1/sha1block_riscv64.s +225 -0
- package/bin/go/src/crypto/sha3/sha3.go +3 -2
- package/bin/go/src/crypto/tls/alert.go +2 -0
- package/bin/go/src/crypto/tls/auth.go +31 -0
- package/bin/go/src/crypto/tls/bogo_config.json +12 -23
- package/bin/go/src/crypto/tls/cipher_suites.go +3 -11
- package/bin/go/src/crypto/tls/common.go +106 -59
- package/bin/go/src/crypto/tls/common_string.go +18 -5
- package/bin/go/src/crypto/tls/conn.go +33 -35
- package/bin/go/src/crypto/tls/defaults.go +26 -20
- package/bin/go/src/crypto/tls/defaults_fips140.go +9 -0
- package/bin/go/src/crypto/tls/ech.go +9 -4
- package/bin/go/src/crypto/tls/generate_cert.go +8 -2
- package/bin/go/src/crypto/tls/handshake_client.go +17 -17
- package/bin/go/src/crypto/tls/handshake_client_tls13.go +8 -3
- package/bin/go/src/crypto/tls/handshake_server.go +26 -19
- package/bin/go/src/crypto/tls/handshake_server_tls13.go +8 -5
- package/bin/go/src/crypto/tls/key_agreement.go +5 -1
- package/bin/go/src/crypto/tls/key_schedule.go +42 -17
- package/bin/go/src/crypto/tls/prf.go +1 -1
- package/bin/go/src/crypto/tls/quic.go +6 -7
- package/bin/go/src/crypto/tls/tls.go +25 -29
- package/bin/go/src/crypto/x509/cert_pool.go +8 -4
- package/bin/go/src/crypto/x509/constraints.go +5 -0
- package/bin/go/src/crypto/x509/parser.go +101 -15
- package/bin/go/src/crypto/x509/pkcs8.go +45 -4
- package/bin/go/src/crypto/x509/pkix/pkix.go +33 -9
- package/bin/go/src/crypto/x509/root.go +113 -0
- package/bin/go/src/crypto/x509/root_darwin.go +8 -4
- package/bin/go/src/crypto/x509/root_plan9.go +2 -23
- package/bin/go/src/crypto/x509/root_unix.go +0 -97
- package/bin/go/src/crypto/x509/root_windows.go +8 -3
- package/bin/go/src/crypto/x509/verify.go +43 -4
- package/bin/go/src/crypto/x509/x509.go +169 -30
- package/bin/go/src/database/sql/closemu.go +119 -0
- package/bin/go/src/database/sql/convert.go +63 -4
- package/bin/go/src/database/sql/driver/driver.go +26 -0
- package/bin/go/src/database/sql/driver/types.go +4 -0
- package/bin/go/src/database/sql/internal/sql.go +22 -0
- package/bin/go/src/database/sql/sql.go +89 -40
- package/bin/go/src/debug/buildinfo/buildinfo.go +0 -13
- package/bin/go/src/debug/dwarf/buf.go +7 -1
- package/bin/go/src/debug/dwarf/class_string.go +3 -2
- package/bin/go/src/debug/elf/file.go +80 -50
- package/bin/go/src/debug/elf/reader.go +1 -1
- package/bin/go/src/debug/gosym/symtab.go +26 -30
- package/bin/go/src/debug/macho/file.go +2 -2
- package/bin/go/src/debug/macho/reloctype_string.go +12 -8
- package/bin/go/src/debug/pe/file.go +6 -3
- package/bin/go/src/encoding/base32/base32.go +29 -31
- package/bin/go/src/encoding/base64/base64.go +24 -29
- package/bin/go/src/encoding/gob/decode.go +7 -1
- package/bin/go/src/encoding/gob/type.go +6 -6
- package/bin/go/src/encoding/hex/hex.go +6 -6
- package/bin/go/src/encoding/json/decode.go +4 -3
- package/bin/go/src/encoding/json/encode.go +1 -2
- package/bin/go/src/encoding/json/fold.go +1 -1
- package/bin/go/src/encoding/json/internal/internal.go +11 -1
- package/bin/go/src/encoding/json/internal/jsonflags/flags.go +17 -9
- package/bin/go/src/encoding/json/internal/jsonopts/options.go +52 -37
- package/bin/go/src/encoding/json/internal/jsonopts/options_format.go +124 -0
- package/bin/go/src/encoding/json/internal/jsontest/_embed/canada_geometry.json.zst +0 -0
- package/bin/go/src/encoding/json/internal/jsontest/_embed/citm_catalog.json.zst +0 -0
- package/bin/go/src/encoding/json/internal/jsontest/_embed/golang_source.json.zst +0 -0
- package/bin/go/src/encoding/json/internal/jsontest/_embed/string_escaped.json.zst +0 -0
- package/bin/go/src/encoding/json/internal/jsontest/_embed/string_unicode.json.zst +0 -0
- package/bin/go/src/encoding/json/internal/jsontest/_embed/synthea_fhir.json.zst +0 -0
- package/bin/go/src/encoding/json/internal/jsontest/_embed/twitter_status.json.zst +0 -0
- package/bin/go/src/encoding/json/internal/jsontest/testdata.go +10 -4
- package/bin/go/src/encoding/json/internal/jsonwire/decode.go +13 -36
- package/bin/go/src/encoding/json/internal/jsonwire/encode.go +7 -7
- package/bin/go/src/encoding/json/internal/jsonwire/wire.go +30 -38
- package/bin/go/src/encoding/json/jsontext/decode.go +49 -14
- package/bin/go/src/encoding/json/jsontext/doc.go +6 -11
- package/bin/go/src/encoding/json/jsontext/encode.go +55 -39
- package/bin/go/src/encoding/json/jsontext/errors.go +34 -3
- package/bin/go/src/encoding/json/jsontext/export.go +14 -0
- package/bin/go/src/encoding/json/jsontext/options.go +8 -8
- package/bin/go/src/encoding/json/jsontext/quote.go +2 -2
- package/bin/go/src/encoding/json/jsontext/state.go +14 -14
- package/bin/go/src/encoding/json/jsontext/token.go +246 -101
- package/bin/go/src/encoding/json/jsontext/value.go +31 -16
- package/bin/go/src/encoding/json/stream.go +14 -2
- package/bin/go/src/encoding/json/v2/arshal.go +100 -114
- package/bin/go/src/encoding/json/v2/arshal_any.go +6 -5
- package/bin/go/src/encoding/json/v2/arshal_default.go +292 -189
- package/bin/go/src/encoding/json/v2/{arshal_inlined.go → arshal_embedded.go} +14 -14
- package/bin/go/src/encoding/json/v2/arshal_funcs.go +28 -47
- package/bin/go/src/encoding/json/v2/arshal_methods.go +98 -29
- package/bin/go/src/encoding/json/v2/arshal_time.go +33 -13
- package/bin/go/src/encoding/json/v2/doc.go +40 -55
- package/bin/go/src/encoding/json/v2/errors.go +29 -9
- package/bin/go/src/encoding/json/v2/fields.go +83 -81
- package/bin/go/src/encoding/json/v2/intern.go +2 -2
- package/bin/go/src/encoding/json/v2/options.go +57 -41
- package/bin/go/src/encoding/json/v2_decode.go +21 -9
- package/bin/go/src/encoding/json/v2_encode.go +21 -10
- package/bin/go/src/encoding/json/v2_indent.go +2 -0
- package/bin/go/src/encoding/json/v2_inject.go +7 -4
- package/bin/go/src/encoding/json/v2_options.go +37 -30
- package/bin/go/src/encoding/json/v2_scanner.go +6 -1
- package/bin/go/src/encoding/json/v2_stream.go +49 -14
- package/bin/go/src/encoding/pem/pem.go +6 -2
- package/bin/go/src/fmt/doc.go +11 -1
- package/bin/go/src/fmt/print.go +69 -82
- package/bin/go/src/go/ast/ast.go +4 -4
- package/bin/go/src/go/ast/filter.go +1 -1
- package/bin/go/src/go/ast/scope.go +2 -2
- package/bin/go/src/go/build/build.go +1 -1
- package/bin/go/src/go/build/constraint/vers.go +4 -1
- package/bin/go/src/go/build/read.go +2 -2
- package/bin/go/src/go/constant/kind_string.go +3 -2
- package/bin/go/src/go/constant/value.go +26 -4
- package/bin/go/src/go/doc/comment/std.go +1 -0
- package/bin/go/src/go/importer/importer.go +4 -3
- package/bin/go/src/go/internal/gccgoimporter/parser.go +2 -0
- package/bin/go/src/go/internal/gcimporter/ureader.go +141 -56
- package/bin/go/src/go/parser/parser.go +11 -22
- package/bin/go/src/go/printer/math.go +28 -0
- package/bin/go/src/go/printer/nodes.go +28 -11
- package/bin/go/src/go/printer/printer.go +3 -1
- package/bin/go/src/go/scanner/errors.go +2 -0
- package/bin/go/src/go/scanner/scanner.go +40 -28
- package/bin/go/src/go/token/position.go +7 -16
- package/bin/go/src/go/types/alias.go +0 -18
- package/bin/go/src/go/types/api.go +4 -10
- package/bin/go/src/go/types/api_predicates.go +2 -2
- package/bin/go/src/go/types/assignments.go +44 -38
- package/bin/go/src/go/types/builtins.go +199 -168
- package/bin/go/src/go/types/call.go +155 -138
- package/bin/go/src/go/types/check.go +0 -83
- package/bin/go/src/go/types/const.go +22 -10
- package/bin/go/src/go/types/conversions.go +19 -19
- package/bin/go/src/go/types/cycles.go +29 -42
- package/bin/go/src/go/types/decl.go +33 -81
- package/bin/go/src/go/types/expr.go +191 -183
- package/bin/go/src/go/types/gotype.go +1 -0
- package/bin/go/src/go/types/hash.go +309 -0
- package/bin/go/src/go/types/index.go +91 -61
- package/bin/go/src/go/types/infer.go +11 -11
- package/bin/go/src/go/types/instantiate.go +27 -15
- package/bin/go/src/go/types/interface.go +2 -2
- package/bin/go/src/go/types/literals.go +56 -32
- package/bin/go/src/go/types/lookup.go +31 -14
- package/bin/go/src/go/types/named.go +58 -54
- package/bin/go/src/go/types/object.go +4 -3
- package/bin/go/src/go/types/operand.go +50 -34
- package/bin/go/src/go/types/range.go +19 -16
- package/bin/go/src/go/types/recording.go +24 -7
- package/bin/go/src/go/types/resolver.go +16 -18
- package/bin/go/src/go/types/scope.go +1 -15
- package/bin/go/src/go/types/selection.go +3 -1
- package/bin/go/src/go/types/signature.go +10 -11
- package/bin/go/src/go/types/stmt.go +34 -28
- package/bin/go/src/go/types/subst.go +82 -5
- package/bin/go/src/go/types/trie.go +93 -0
- package/bin/go/src/go/types/typelists.go +28 -0
- package/bin/go/src/go/types/typestring.go +5 -9
- package/bin/go/src/go/types/typexpr.go +17 -28
- package/bin/go/src/go/types/unify.go +12 -3
- package/bin/go/src/go/types/universe.go +12 -40
- package/bin/go/src/go/types/version.go +4 -0
- package/bin/go/src/go.mod +5 -5
- package/bin/go/src/go.sum +8 -8
- package/bin/go/src/hash/maphash/hasher.go +139 -0
- package/bin/go/src/hash/maphash/maphash.go +59 -4
- package/bin/go/src/html/template/attr_string.go +3 -2
- package/bin/go/src/html/template/delim_string.go +3 -2
- package/bin/go/src/html/template/element_string.go +3 -2
- package/bin/go/src/html/template/jsctx_string.go +3 -2
- package/bin/go/src/html/template/state_string.go +3 -2
- package/bin/go/src/html/template/template.go +7 -4
- package/bin/go/src/html/template/transition.go +1 -1
- package/bin/go/src/html/template/urlpart_string.go +3 -2
- package/bin/go/src/image/format.go +9 -0
- package/bin/go/src/image/gif/reader.go +18 -0
- package/bin/go/src/image/jpeg/huffman.go +22 -3
- package/bin/go/src/image/jpeg/reader.go +54 -29
- package/bin/go/src/image/jpeg/scan.go +68 -38
- package/bin/go/src/image/png/writer.go +8 -0
- package/bin/go/src/index/suffixarray/suffixarray.go +14 -6
- package/bin/go/src/internal/abi/abi_generic.go +1 -1
- package/bin/go/src/internal/abi/abi_s390x.go +0 -2
- package/bin/go/src/internal/abi/compiletype.go +30 -0
- package/bin/go/src/internal/abi/iface.go +13 -1
- package/bin/go/src/internal/abi/map.go +21 -3
- package/bin/go/src/internal/abi/type.go +136 -27
- package/bin/go/src/internal/buildcfg/exp.go +8 -8
- package/bin/go/src/internal/buildcfg/zbootstrap.go +1 -1
- package/bin/go/src/internal/bytealg/bytealg.go +16 -16
- package/bin/go/src/internal/bytealg/compare_s390x.s +0 -24
- package/bin/go/src/internal/bytealg/equal_s390x.s +0 -18
- package/bin/go/src/internal/bytealg/indexbyte_arm64.s +28 -0
- package/bin/go/src/internal/bytealg/indexbyte_s390x.s +0 -33
- package/bin/go/src/internal/coverage/encodemeta/encode.go +1 -1
- package/bin/go/src/internal/cpu/cpu.go +22 -7
- package/bin/go/src/internal/cpu/cpu_arm64.go +8 -1
- package/bin/go/src/internal/cpu/cpu_arm64.s +7 -0
- package/bin/go/src/internal/cpu/cpu_arm64_darwin.go +2 -0
- package/bin/go/src/internal/cpu/cpu_arm64_freebsd.go +2 -1
- package/bin/go/src/internal/cpu/cpu_arm64_hwcap.go +2 -0
- package/bin/go/src/internal/cpu/cpu_arm64_openbsd.go +6 -1
- package/bin/go/src/internal/cpu/cpu_arm64_other.go +1 -1
- package/bin/go/src/internal/cpu/cpu_arm64_windows.go +26 -0
- package/bin/go/src/internal/cpu/cpu_loong64.go +14 -2
- package/bin/go/src/internal/cpu/cpu_riscv64.go +10 -0
- package/bin/go/src/internal/cpu/cpu_riscv64_linux.go +21 -0
- package/bin/go/src/internal/cpu/cpu_windows.go +20 -0
- package/bin/go/src/internal/cpu/cpu_x86.go +2 -0
- package/bin/go/src/internal/filepathlite/path_windows.go +30 -17
- package/bin/go/src/internal/fuzz/fuzz.go +5 -1
- package/bin/go/src/internal/fuzz/mutator.go +2 -2
- package/bin/go/src/internal/fuzz/worker.go +1 -1
- package/bin/go/src/internal/gate/gate.go +76 -0
- package/bin/go/src/internal/godebugs/table.go +29 -10
- package/bin/go/src/internal/goexperiment/exp_mapsplitgroup_off.go +8 -0
- package/bin/go/src/internal/goexperiment/exp_mapsplitgroup_on.go +8 -0
- package/bin/go/src/internal/goexperiment/flags.go +5 -3
- package/bin/go/src/internal/goversion/goversion.go +1 -1
- package/bin/go/src/internal/lazyregexp/lazyre.go +4 -0
- package/bin/go/src/internal/nettest/conn.go +437 -0
- package/bin/go/src/internal/nettest/listener.go +148 -0
- package/bin/go/src/internal/nettest/packetconn.go +250 -0
- package/bin/go/src/internal/nettest/queue.go +33 -0
- package/bin/go/src/internal/pkgbits/syncmarker_string.go +4 -4
- package/bin/go/src/internal/pkgbits/version.go +27 -1
- package/bin/go/src/internal/platform/supported.go +8 -10
- package/bin/go/src/internal/platform/zosarch.go +1 -3
- package/bin/go/src/internal/poll/fd_mutex.go +49 -10
- package/bin/go/src/internal/poll/fd_unix.go +6 -1
- package/bin/go/src/internal/poll/fd_windows.go +175 -191
- package/bin/go/src/internal/poll/fd_writev_libc.go +1 -1
- package/bin/go/src/internal/poll/fd_writev_unix.go +1 -1
- package/bin/go/src/internal/poll/file_plan9.go +4 -4
- package/bin/go/src/internal/poll/sendfile_windows.go +1 -3
- package/bin/go/src/internal/poll/splice_linux.go +1 -1
- package/bin/go/src/internal/profile/encode.go +1 -1
- package/bin/go/src/internal/profile/profile.go +5 -3
- package/bin/go/src/internal/profilerecord/profilerecord.go +2 -2
- package/bin/go/src/internal/reflectlite/value.go +1 -15
- package/bin/go/src/internal/runtime/atomic/atomic_386.go +0 -6
- package/bin/go/src/internal/runtime/atomic/atomic_amd64.go +0 -6
- package/bin/go/src/internal/runtime/atomic/atomic_andor_generic.go +0 -11
- package/bin/go/src/internal/runtime/atomic/atomic_arm.go +0 -6
- package/bin/go/src/internal/runtime/atomic/atomic_loong64.go +2 -2
- package/bin/go/src/internal/runtime/atomic/atomic_loong64.s +22 -11
- package/bin/go/src/internal/runtime/atomic/atomic_mipsx.go +0 -10
- package/bin/go/src/internal/runtime/atomic/atomic_riscv64.s +4 -4
- package/bin/go/src/internal/runtime/atomic/atomic_s390x.go +0 -6
- package/bin/go/src/internal/runtime/atomic/atomic_wasm.go +0 -31
- package/bin/go/src/internal/runtime/atomic/linkname.go +34 -0
- package/bin/go/src/internal/runtime/exithook/hooks.go +0 -4
- package/bin/go/src/internal/runtime/gc/scan/expand_amd64.s +2285 -2285
- package/bin/go/src/internal/runtime/gc/scan/mkasm.go +1 -1
- package/bin/go/src/internal/runtime/gc/scan/scan_amd64.go +2 -1
- package/bin/go/src/internal/runtime/gc/scan/scan_amd64.s +4 -2
- package/bin/go/src/internal/runtime/maps/group.go +22 -13
- package/bin/go/src/internal/runtime/maps/map.go +35 -14
- package/bin/go/src/internal/runtime/maps/memhash_386.s +408 -0
- package/bin/go/src/internal/runtime/maps/memhash_aes.go +38 -0
- package/bin/go/src/internal/runtime/maps/memhash_aes_asm.go +24 -0
- package/bin/go/src/internal/runtime/maps/memhash_aes_simd.go +49 -0
- package/bin/go/src/internal/runtime/maps/memhash_align_check.go +10 -0
- package/bin/go/src/internal/runtime/maps/memhash_align_nocheck.go +16 -0
- package/bin/go/src/internal/runtime/maps/memhash_amd64.s +426 -0
- package/bin/go/src/internal/runtime/maps/memhash_arm64.s +366 -0
- package/bin/go/src/internal/runtime/maps/memhash_noaes.go +43 -0
- package/bin/go/src/internal/runtime/maps/memhash_nosimd_amd64.s +33 -0
- package/bin/go/src/internal/runtime/maps/runtime.go +37 -88
- package/bin/go/src/internal/runtime/maps/runtime_alg.go +93 -0
- package/bin/go/src/internal/runtime/maps/runtime_fast32.go +111 -97
- package/bin/go/src/internal/runtime/maps/runtime_fast64.go +137 -98
- package/bin/go/src/internal/runtime/maps/runtime_faststr.go +96 -89
- package/bin/go/src/{runtime/hash32.go → internal/runtime/maps/runtime_hash32.go} +8 -10
- package/bin/go/src/{runtime/hash64.go → internal/runtime/maps/runtime_hash64.go} +8 -8
- package/bin/go/src/internal/runtime/maps/table.go +66 -3
- package/bin/go/src/internal/runtime/math/math.go +0 -21
- package/bin/go/src/internal/runtime/startlinetest/func_amd64.s +2 -1
- package/bin/go/src/internal/runtime/sys/dit_arm64.go +3 -0
- package/bin/go/src/internal/runtime/sys/dit_arm64.s +16 -3
- package/bin/go/src/internal/runtime/syscall/linux/asm_linux_s390x.s +0 -23
- package/bin/go/src/internal/runtime/syscall/windows/asm_windows_386.s +7 -4
- package/bin/go/src/internal/runtime/syscall/windows/asm_windows_amd64.s +10 -8
- package/bin/go/src/internal/runtime/syscall/windows/asm_windows_arm64.s +0 -1
- package/bin/go/src/internal/runtime/syscall/windows/defs_windows.go +4 -0
- package/bin/go/src/internal/runtime/syscall/windows/syscall_windows.go +7 -9
- package/bin/go/src/internal/strconv/atof.go +69 -42
- package/bin/go/src/internal/strconv/atoi.go +1 -0
- package/bin/go/src/internal/strconv/ftoa.go +329 -357
- package/bin/go/src/internal/strconv/itoa.go +53 -59
- package/bin/go/src/internal/strconv/pow10gen.go +15 -3
- package/bin/go/src/internal/strconv/pow10tab.go +670 -670
- package/bin/go/src/internal/strconv/uscale.go +290 -0
- package/bin/go/src/internal/stringslite/strings.go +14 -42
- package/bin/go/src/internal/syscall/unix/asm_openbsd.s +0 -2
- package/bin/go/src/internal/syscall/unix/at.go +1 -1
- package/bin/go/src/internal/syscall/unix/at_fstatat.go +1 -1
- package/bin/go/src/internal/syscall/unix/at_libc2.go +1 -1
- package/bin/go/src/internal/syscall/unix/at_openbsd.go +0 -2
- package/bin/go/src/internal/syscall/unix/faccessat_bsd.go +1 -1
- package/bin/go/src/internal/syscall/unix/faccessat_openbsd.go +0 -2
- package/bin/go/src/internal/syscall/windows/at_windows.go +5 -5
- package/bin/go/src/internal/syscall/windows/net_windows.go +1 -0
- package/bin/go/src/internal/syscall/windows/string_windows.go +6 -3
- package/bin/go/src/internal/syscall/windows/syscall_windows.go +2 -0
- package/bin/go/src/internal/syscall/windows/types_windows.go +89 -4
- package/bin/go/src/internal/syscall/windows/zsyscall_windows.go +7 -0
- package/bin/go/src/internal/testenv/testenv.go +24 -1
- package/bin/go/src/internal/trace/event.go +1 -1
- package/bin/go/src/internal/trace/tracev2/events.go +2 -0
- package/bin/go/src/internal/trace/traceviewer/pprof.go +1 -0
- package/bin/go/src/internal/types/errors/generrordocs.go +1 -1
- package/bin/go/src/io/fs/fs.go +4 -1
- package/bin/go/src/io/fs/glob.go +1 -1
- package/bin/go/src/io/fs/readdir.go +3 -3
- package/bin/go/src/io/fs/readfile.go +3 -3
- package/bin/go/src/io/fs/stat.go +1 -1
- package/bin/go/src/io/fs/sub.go +4 -2
- package/bin/go/src/iter/iter.go +2 -2
- package/bin/go/src/log/slog/handler.go +0 -1
- package/bin/go/src/log/slog/json_handler.go +7 -1
- package/bin/go/src/log/slog/logger.go +16 -0
- package/bin/go/src/log/slog/text_handler.go +10 -1
- package/bin/go/src/log/slog/value.go +1 -1
- package/bin/go/src/log/syslog/doc.go +5 -0
- package/bin/go/src/math/abs.go +1 -1
- package/bin/go/src/math/big/accuracy_string.go +4 -4
- package/bin/go/src/math/big/arith.go +1 -1
- package/bin/go/src/math/big/arith_loong64.s +2 -4
- package/bin/go/src/math/big/float.go +2 -0
- package/bin/go/src/math/big/ftoa.go +11 -5
- package/bin/go/src/math/big/int.go +84 -1
- package/bin/go/src/math/big/intconv.go +19 -4
- package/bin/go/src/math/big/internal/asmgen/loong64.go +2 -0
- package/bin/go/src/math/big/nat.go +68 -17
- package/bin/go/src/math/big/natdiv.go +8 -5
- package/bin/go/src/math/big/roundingmode_string.go +3 -2
- package/bin/go/src/math/copysign.go +1 -2
- package/bin/go/src/math/exp2_asm.go +1 -1
- package/bin/go/src/math/exp2_noasm.go +1 -1
- package/bin/go/src/math/exp_asm.go +1 -1
- package/bin/go/src/math/exp_loong64.s +4 -12
- package/bin/go/src/math/exp_noasm.go +1 -1
- package/bin/go/src/math/exp_riscv64.s +236 -0
- package/bin/go/src/math/nextafter.go +4 -2
- package/bin/go/src/math/pow10.go +1 -1
- package/bin/go/src/math/rand/v2/rand.go +14 -4
- package/bin/go/src/mime/type.go +3 -2
- package/bin/go/src/net/dial.go +10 -6
- package/bin/go/src/net/dnsclient_unix.go +37 -8
- package/bin/go/src/net/dnsconfig.go +6 -0
- package/bin/go/src/net/fd_plan9.go +13 -6
- package/bin/go/src/net/fd_unix.go +3 -7
- package/bin/go/src/net/fd_windows.go +4 -9
- package/bin/go/src/net/file_plan9.go +1 -1
- package/bin/go/src/net/file_posix.go +1 -5
- package/bin/go/src/net/http/client.go +21 -4
- package/bin/go/src/net/http/clientconn.go +20 -1
- package/bin/go/src/net/http/clone.go +1 -10
- package/bin/go/src/net/http/cookie.go +5 -6
- package/bin/go/src/net/http/cookiejar/jar.go +6 -4
- package/bin/go/src/net/http/fcgi/fcgi.go +1 -2
- package/bin/go/src/net/http/fs.go +8 -1
- package/bin/go/src/net/http/http.go +29 -12
- package/bin/go/src/net/http/http2.go +561 -0
- package/bin/go/src/net/http/httptest/server.go +305 -60
- package/bin/go/src/net/http/httptrace/trace.go +78 -27
- package/bin/go/src/net/http/httputil/reverseproxy.go +0 -30
- package/bin/go/src/net/http/internal/common.go +14 -0
- package/bin/go/src/net/http/internal/http2/api.go +161 -0
- package/bin/go/src/net/http/internal/http2/ascii.go +53 -0
- package/bin/go/src/net/http/internal/http2/ciphers.go +641 -0
- package/bin/go/src/net/http/internal/http2/client_conn_pool.go +285 -0
- package/bin/go/src/net/http/internal/http2/config.go +118 -0
- package/bin/go/src/net/http/internal/http2/databuffer.go +146 -0
- package/bin/go/src/net/http/internal/http2/errors.go +173 -0
- package/bin/go/src/net/http/internal/http2/flow.go +175 -0
- package/bin/go/src/net/http/internal/http2/frame.go +1905 -0
- package/bin/go/src/net/http/internal/http2/gotrack.go +181 -0
- package/bin/go/src/net/http/internal/http2/http2.go +403 -0
- package/bin/go/src/net/http/internal/http2/pipe.go +184 -0
- package/bin/go/src/net/http/internal/http2/server.go +3238 -0
- package/bin/go/src/net/http/internal/http2/transport.go +3267 -0
- package/bin/go/src/net/http/internal/http2/write.go +380 -0
- package/bin/go/src/net/http/internal/http2/writesched.go +289 -0
- package/bin/go/src/net/http/internal/http2/writesched_priority_rfc9218.go +224 -0
- package/bin/go/src/net/http/internal/http2/writesched_roundrobin.go +119 -0
- package/bin/go/src/net/http/internal/httpcommon/httpcommon.go +8 -0
- package/bin/go/src/net/http/internal/httpsfv/httpsfv.go +666 -0
- package/bin/go/src/net/http/internal/sniff.go +304 -0
- package/bin/go/src/net/http/omithttp2.go +28 -49
- package/bin/go/src/net/http/pprof/pprof.go +11 -17
- package/bin/go/src/net/http/request.go +30 -3
- package/bin/go/src/net/http/response.go +6 -2
- package/bin/go/src/net/http/server.go +366 -144
- package/bin/go/src/net/http/sniff.go +2 -289
- package/bin/go/src/net/http/transfer.go +64 -21
- package/bin/go/src/net/http/transport.go +288 -83
- package/bin/go/src/net/ip.go +4 -0
- package/bin/go/src/net/ipsock_plan9.go +4 -4
- package/bin/go/src/net/ipsock_posix.go +8 -2
- package/bin/go/src/net/lookup.go +10 -0
- package/bin/go/src/net/lookup_windows.go +1 -1
- package/bin/go/src/net/mail/message.go +8 -3
- package/bin/go/src/net/net.go +2 -0
- package/bin/go/src/net/netip/netip.go +68 -61
- package/bin/go/src/net/sock_posix.go +1 -4
- package/bin/go/src/net/textproto/reader.go +11 -3
- package/bin/go/src/net/udpsock_plan9.go +2 -7
- package/bin/go/src/net/unixsock.go +11 -3
- package/bin/go/src/net/url/url.go +33 -0
- package/bin/go/src/os/dir_darwin.go +7 -0
- package/bin/go/src/os/exec/exec.go +16 -2
- package/bin/go/src/os/exec.go +1 -0
- package/bin/go/src/os/file.go +8 -1
- package/bin/go/src/os/root_windows.go +5 -1
- package/bin/go/src/os/signal/doc.go +3 -2
- package/bin/go/src/os/signal/signal.go +18 -6
- package/bin/go/src/os/statat_unix.go +5 -1
- package/bin/go/src/path/filepath/path.go +4 -0
- package/bin/go/src/reflect/asm_s390x.s +0 -10
- package/bin/go/src/reflect/iter.go +13 -13
- package/bin/go/src/reflect/makefunc.go +2 -1
- package/bin/go/src/reflect/map.go +61 -18
- package/bin/go/src/reflect/type.go +63 -46
- package/bin/go/src/reflect/value.go +59 -16
- package/bin/go/src/regexp/exec.go +5 -5
- package/bin/go/src/regexp/regexp.go +382 -319
- package/bin/go/src/regexp/syntax/parse.go +19 -10
- package/bin/go/src/runtime/HACKING.md +19 -0
- package/bin/go/src/runtime/_mkmalloc/constants.go +6 -4
- package/bin/go/src/runtime/_mkmalloc/go.mod +1 -1
- package/bin/go/src/runtime/_mkmalloc/mkmalloc.go +405 -64
- package/bin/go/src/runtime/alg.go +21 -53
- package/bin/go/src/runtime/asm_386.s +11 -461
- package/bin/go/src/runtime/asm_amd64.s +30 -537
- package/bin/go/src/runtime/asm_arm.s +4 -39
- package/bin/go/src/runtime/asm_arm64.s +15 -428
- package/bin/go/src/runtime/asm_loong64.s +37 -47
- package/bin/go/src/runtime/asm_mips64x.s +15 -15
- package/bin/go/src/runtime/asm_mipsx.s +0 -15
- package/bin/go/src/runtime/asm_ppc64x.h +0 -16
- package/bin/go/src/runtime/asm_ppc64x.s +13 -59
- package/bin/go/src/runtime/asm_riscv64.s +30 -91
- package/bin/go/src/runtime/asm_s390x.s +49 -49
- package/bin/go/src/runtime/asm_wasm.s +0 -15
- package/bin/go/src/runtime/atomic_riscv64.s +1 -1
- package/bin/go/src/runtime/cgo/abi_riscv64.h +72 -0
- package/bin/go/src/runtime/cgo/asm_riscv64.s +7 -48
- package/bin/go/src/runtime/cgo/callbacks.go +0 -42
- package/bin/go/src/runtime/cgo/callbacks_unix.go +58 -0
- package/bin/go/src/runtime/cgo/cgo.go +6 -3
- package/bin/go/src/runtime/cgo/gcc_aix_ppc64.S +21 -9
- package/bin/go/src/runtime/cgo/gcc_android.c +0 -26
- package/bin/go/src/runtime/cgo/gcc_clearenv.c +1 -1
- package/bin/go/src/runtime/cgo/gcc_fatalf.c +14 -3
- package/bin/go/src/runtime/cgo/{gcc_libinit.c → gcc_libinit_unix.c} +18 -65
- package/bin/go/src/runtime/cgo/gcc_libinit_windows.c +23 -35
- package/bin/go/src/runtime/cgo/gcc_linux_ppc64x.S +16 -7
- package/bin/go/src/runtime/cgo/gcc_netbsd.c +8 -56
- package/bin/go/src/runtime/cgo/gcc_s390x.S +13 -4
- package/bin/go/src/runtime/cgo/gcc_sigaction.c +1 -1
- package/bin/go/src/runtime/cgo/gcc_unix.c +63 -0
- package/bin/go/src/runtime/cgo/gcc_util.c +0 -19
- package/bin/go/src/runtime/cgo/handle.go +3 -0
- package/bin/go/src/runtime/cgo/libcgo.h +7 -10
- package/bin/go/src/runtime/cgo/libcgo_unix.h +2 -10
- package/bin/go/src/runtime/cgo/pthread_unix.c +138 -0
- package/bin/go/src/runtime/cgo/sigaction.go +1 -1
- package/bin/go/src/runtime/cgo/windows.go +18 -1
- package/bin/go/src/runtime/cgo_ppc64x.go +1 -1
- package/bin/go/src/runtime/cgo_sigaction.go +1 -1
- package/bin/go/src/runtime/cgocall.go +10 -2
- package/bin/go/src/runtime/chan.go +2 -16
- package/bin/go/src/runtime/coro.go +2 -2
- package/bin/go/src/runtime/cpuflags.go +4 -3
- package/bin/go/src/runtime/debug/garbage.go +6 -6
- package/bin/go/src/runtime/debug/mod.go +1 -1
- package/bin/go/src/runtime/debug/stack.go +1 -1
- package/bin/go/src/runtime/debugcall.go +0 -3
- package/bin/go/src/runtime/error.go +6 -0
- package/bin/go/src/runtime/extern.go +5 -3
- package/bin/go/src/runtime/heapdump.go +1 -1
- package/bin/go/src/runtime/iface.go +20 -10
- package/bin/go/src/runtime/libinit.go +48 -0
- package/bin/go/src/runtime/lock_js.go +4 -2
- package/bin/go/src/runtime/lock_spinbit.go +13 -12
- package/bin/go/src/runtime/lock_wasip1.go +4 -2
- package/bin/go/src/runtime/lockrank.go +24 -21
- package/bin/go/src/runtime/lockrank_off.go +5 -2
- package/bin/go/src/runtime/lockrank_on.go +8 -7
- package/bin/go/src/runtime/malloc.go +10 -26
- package/bin/go/src/runtime/malloc_generated.go +819 -8628
- package/bin/go/src/runtime/malloc_stubs.go +187 -197
- package/bin/go/src/runtime/malloc_tables_generated.go +16 -882
- package/bin/go/src/runtime/map.go +4 -4
- package/bin/go/src/runtime/mbitmap.go +3 -1
- package/bin/go/src/runtime/mem.go +2 -6
- package/bin/go/src/runtime/mem_sbrk.go +4 -0
- package/bin/go/src/runtime/memclr_s390x.s +0 -5
- package/bin/go/src/runtime/memmove_s390x.s +0 -7
- package/bin/go/src/runtime/metrics/doc.go +5 -29
- package/bin/go/src/runtime/metrics/sample.go +3 -0
- package/bin/go/src/runtime/metrics.go +3 -2
- package/bin/go/src/runtime/mgc.go +41 -25
- package/bin/go/src/runtime/mgcmark.go +5 -0
- package/bin/go/src/runtime/mgcmark_greenteagc.go +1 -1
- package/bin/go/src/runtime/mgcpacer.go +1 -3
- package/bin/go/src/runtime/mgcscavenge.go +1 -1
- package/bin/go/src/runtime/mheap.go +1 -10
- package/bin/go/src/runtime/mklockrank.go +6 -1
- package/bin/go/src/runtime/mkpreempt.go +7 -0
- package/bin/go/src/runtime/mprof.go +12 -23
- package/bin/go/src/runtime/os2_aix.go +3 -3
- package/bin/go/src/runtime/os3_solaris.go +10 -0
- package/bin/go/src/runtime/os_aix.go +9 -2
- package/bin/go/src/runtime/os_darwin.go +3 -8
- package/bin/go/src/runtime/os_dragonfly.go +10 -0
- package/bin/go/src/runtime/os_js.go +10 -0
- package/bin/go/src/runtime/os_linux32.go +19 -6
- package/bin/go/src/runtime/os_netbsd.go +10 -0
- package/bin/go/src/runtime/os_openbsd.go +10 -0
- package/bin/go/src/runtime/os_plan9.go +10 -0
- package/bin/go/src/runtime/os_wasip1.go +10 -0
- package/bin/go/src/runtime/os_windows.go +45 -12
- package/bin/go/src/runtime/os_workdir_ios_arm64.go +98 -0
- package/bin/go/src/runtime/os_workdir_stub.go +9 -0
- package/bin/go/src/runtime/panic.go +93 -8
- package/bin/go/src/runtime/plugin.go +1 -3
- package/bin/go/src/runtime/pprof/pprof.go +11 -14
- package/bin/go/src/runtime/pprof/protomem.go +8 -15
- package/bin/go/src/runtime/preempt_loong64.s +8 -4
- package/bin/go/src/runtime/preempt_noxreg.go +2 -0
- package/bin/go/src/runtime/preempt_xreg.go +29 -2
- package/bin/go/src/runtime/print.go +9 -1
- package/bin/go/src/runtime/proc.go +68 -17
- package/bin/go/src/runtime/race_riscv64.s +40 -83
- package/bin/go/src/runtime/race_s390x.s +0 -16
- package/bin/go/src/runtime/rand.go +40 -12
- package/bin/go/src/runtime/{rt0_linux_ppc64le.s → rt0_linux_ppc64x.s} +12 -2
- package/bin/go/src/runtime/runtime-gdb.py +13 -2
- package/bin/go/src/runtime/runtime1.go +69 -18
- package/bin/go/src/runtime/runtime2.go +23 -22
- package/bin/go/src/runtime/secret/secret.go +7 -2
- package/bin/go/src/runtime/secret.go +27 -9
- package/bin/go/src/runtime/secret_nosecret.go +1 -1
- package/bin/go/src/runtime/sigaction.go +1 -1
- package/bin/go/src/runtime/signal_unix.go +5 -3
- package/bin/go/src/runtime/softfloat64.go +7 -2
- package/bin/go/src/runtime/string.go +4 -1
- package/bin/go/src/runtime/stubs.go +14 -4
- package/bin/go/src/runtime/stubs_amd64.go +4 -0
- package/bin/go/src/runtime/stubs_arm.go +10 -1
- package/bin/go/src/runtime/stubs_arm64.go +13 -0
- package/bin/go/src/runtime/stubs_loong64.go +18 -0
- package/bin/go/src/runtime/stubs_mips64x.go +9 -0
- package/bin/go/src/runtime/stubs_mipsx.go +11 -0
- package/bin/go/src/runtime/stubs_ppc64x.go +15 -0
- package/bin/go/src/runtime/stubs_riscv64.go +13 -0
- package/bin/go/src/runtime/stubs_s390x.go +18 -0
- package/bin/go/src/runtime/symtab.go +15 -16
- package/bin/go/src/runtime/synctest.go +2 -4
- package/bin/go/src/runtime/sys_aix_ppc64.s +9 -0
- package/bin/go/src/runtime/sys_darwin.go +2 -20
- package/bin/go/src/runtime/sys_darwin_amd64.s +1 -4
- package/bin/go/src/runtime/sys_darwin_arm64.s +3 -6
- package/bin/go/src/runtime/sys_freebsd_riscv64.s +2 -2
- package/bin/go/src/runtime/sys_ios_arm64.go +151 -0
- package/bin/go/src/runtime/sys_ios_arm64.s +78 -0
- package/bin/go/src/runtime/sys_linux_amd64.s +7 -1
- package/bin/go/src/runtime/sys_linux_loong64.s +8 -14
- package/bin/go/src/runtime/sys_linux_ppc64x.s +0 -12
- package/bin/go/src/runtime/sys_linux_riscv64.s +2 -2
- package/bin/go/src/runtime/sys_openbsd.go +1 -1
- package/bin/go/src/runtime/sys_openbsd_riscv64.s +16 -16
- package/bin/go/src/runtime/syscall_windows.go +2 -6
- package/bin/go/src/runtime/time.go +19 -57
- package/bin/go/src/runtime/trace/subscribe.go +0 -3
- package/bin/go/src/runtime/traceback.go +90 -13
- package/bin/go/src/runtime/traceregion.go +3 -3
- package/bin/go/src/runtime/tracestring.go +5 -0
- package/bin/go/src/runtime/type.go +85 -15
- package/bin/go/src/runtime/utf8.go +2 -2
- package/bin/go/src/simd/archsimd/_gen/go.mod +2 -2
- package/bin/go/src/simd/archsimd/_gen/go.sum +2 -2
- package/bin/go/src/simd/archsimd/_gen/main.go +106 -15
- package/bin/go/src/simd/archsimd/_gen/midway/comments.yaml +151 -0
- package/bin/go/src/simd/archsimd/_gen/midway/intersect_simd_ops.go +836 -0
- package/bin/go/src/simd/archsimd/_gen/sgutil/asbits.go +139 -0
- package/bin/go/src/simd/archsimd/_gen/sgutil/compare_natural.go +73 -0
- package/bin/go/src/simd/archsimd/_gen/sgutil/formatted_files.go +66 -0
- package/bin/go/src/simd/archsimd/_gen/sgutil/insert_ordered_map.go +159 -0
- package/bin/go/src/simd/archsimd/_gen/sgutil/merge_generic_ops.go +245 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/arch.go +173 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/arm64/emit.go +166 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/arm64/instruction.go +642 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/arm64/load.go +54 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/arm64/operands.go +406 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/etetest.sh +1 -1
- package/bin/go/src/simd/archsimd/_gen/simdgen/gen_simdGenericOps.go +19 -52
- package/bin/go/src/simd/archsimd/_gen/simdgen/gen_simdIntrinsics.go +162 -98
- package/bin/go/src/simd/archsimd/_gen/simdgen/gen_simdMachineOps.go +50 -19
- package/bin/go/src/simd/archsimd/_gen/simdgen/gen_simdTypes.go +198 -140
- package/bin/go/src/simd/archsimd/_gen/simdgen/gen_simdrules.go +278 -57
- package/bin/go/src/simd/archsimd/_gen/simdgen/gen_simdssa.go +133 -68
- package/bin/go/src/simd/archsimd/_gen/simdgen/gen_utility.go +163 -30
- package/bin/go/src/simd/archsimd/_gen/simdgen/go_amd64.yaml +1 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/go_arm64.yaml +1 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/godefs.go +113 -15
- package/bin/go/src/simd/archsimd/_gen/simdgen/main.go +62 -17
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/AddSub/categories.yaml +12 -12
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/AddSub/{go.yaml → go_amd64.yaml} +12 -12
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/AddSub/go_arm64.yaml +91 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/BitwiseLogic/categories.yaml +11 -3
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/BitwiseLogic/go_arm64.yaml +43 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Compares/go_arm64.yaml +81 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Converts/categories.yaml +11 -6
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Converts/{go.yaml → go_amd64.yaml} +8 -8
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Converts/go_arm64.yaml +358 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/FPonlyArith/categories.yaml +5 -5
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/FPonlyArith/{go.yaml → go_amd64.yaml} +4 -4
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/FPonlyArith/go_arm64.yaml +52 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/GaloisField/categories.yaml +29 -11
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/GaloisField/{go.yaml → go_amd64.yaml} +1 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/GaloisField/go_arm64.yaml +10 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/IntOnlyArith/categories.yaml +2 -5
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/IntOnlyArith/{go.yaml → go_amd64.yaml} +2 -3
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/IntOnlyArith/go_arm64.yaml +35 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/MLOps/categories.yaml +5 -8
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/MLOps/{go.yaml → go_amd64.yaml} +7 -5
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/MLOps/go_arm64.yaml +31 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/MinMax/go_arm64.yaml +61 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Moves/categories.yaml +79 -23
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Moves/{go.yaml → go_amd64.yaml} +213 -104
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Moves/go_arm64.yaml +264 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Mul/categories.yaml +6 -2
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Mul/{go.yaml → go_amd64.yaml} +3 -3
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Mul/go_arm64.yaml +38 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/NegAbs/categories.yaml +7 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/NegAbs/go_arm64.yaml +36 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Others/categories.yaml +5 -1
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Others/go_arm64.yaml +19 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Reduce/categories.yaml +16 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Reduce/go_arm64.yaml +71 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/ShiftRotate/categories.yaml +156 -41
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/ShiftRotate/go_amd64.yaml +299 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/ShiftRotate/go_arm64.yaml +202 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/types.yaml +2 -0
- package/bin/go/src/simd/archsimd/_gen/simdgen/xed.go +44 -11
- package/bin/go/src/simd/archsimd/_gen/tmplgen/main.go +668 -123
- package/bin/go/src/simd/archsimd/_gen/unify/closure.go +1 -1
- package/bin/go/src/simd/archsimd/_gen/unify/env.go +35 -3
- package/bin/go/src/simd/archsimd/_gen/unify/yaml.go +4 -4
- package/bin/go/src/simd/archsimd/_gen/wasmgen/main.go +2064 -0
- package/bin/go/src/simd/archsimd/clmul_arm64.go +79 -0
- package/bin/go/src/simd/archsimd/clmul_emulated.go +103 -0
- package/bin/go/src/simd/archsimd/compare_gen_arm64.go +155 -0
- package/bin/go/src/simd/archsimd/cpu.go +1 -1
- package/bin/go/src/simd/archsimd/cpu_other.go +21 -0
- package/bin/go/src/simd/archsimd/doc.go +0 -2
- package/bin/go/src/simd/archsimd/dummy.s +1 -1
- package/bin/go/src/simd/archsimd/generate.go +1 -1
- package/bin/go/src/simd/archsimd/internal/test_helpers/checkslices.go +2 -2
- package/bin/go/src/simd/archsimd/maskmerge_gen_amd64.go +330 -0
- package/bin/go/src/simd/archsimd/maskmerge_gen_arm64.go +167 -0
- package/bin/go/src/simd/archsimd/ops_amd64.go +4210 -2475
- package/bin/go/src/simd/archsimd/ops_arm64.go +2186 -0
- package/bin/go/src/simd/archsimd/ops_emulated_amd64.go +205 -0
- package/bin/go/src/simd/archsimd/ops_emulated_wasm.go +212 -0
- package/bin/go/src/simd/archsimd/ops_internal_amd64.go +500 -56
- package/bin/go/src/simd/archsimd/ops_internal_arm64.go +234 -0
- package/bin/go/src/simd/archsimd/ops_wasm.go +1795 -0
- package/bin/go/src/simd/archsimd/other_gen_amd64.go +576 -72
- package/bin/go/src/simd/archsimd/other_gen_arm64.go +519 -0
- package/bin/go/src/simd/archsimd/shuffles_amd64.go +217 -76
- package/bin/go/src/simd/archsimd/slice_gen_amd64.go +594 -532
- package/bin/go/src/simd/archsimd/slice_gen_arm64.go +125 -0
- package/bin/go/src/simd/archsimd/slicepart_128.go +302 -0
- package/bin/go/src/simd/archsimd/slicepart_amd64.go +36 -235
- package/bin/go/src/simd/archsimd/slicepart_arm64.go +217 -0
- package/bin/go/src/simd/archsimd/slicepart_wasm.go +217 -0
- package/bin/go/src/simd/archsimd/string.go +1 -1
- package/bin/go/src/simd/archsimd/types_amd64.go +165 -341
- package/bin/go/src/simd/archsimd/types_arm64.go +224 -0
- package/bin/go/src/simd/archsimd/types_wasm.go +354 -0
- package/bin/go/src/simd/archsimd/unsafe_helpers.go +60 -0
- package/bin/go/src/simd/doc.go +91 -0
- package/bin/go/src/simd/dummy.s +7 -0
- package/bin/go/src/simd/internal/bridge/decls_amd64.go +4085 -0
- package/bin/go/src/simd/internal/bridge/decls_arm64.go +1369 -0
- package/bin/go/src/simd/internal/bridge/decls_wasm.go +1369 -0
- package/bin/go/src/simd/internal/bridge/import_hook.go +13 -0
- package/bin/go/src/simd/internal/bridge/simd_emulated.go +3275 -0
- package/bin/go/src/simd/internal/bridge/simd_types_emulated.go +95 -0
- package/bin/go/src/simd/internal/bridge/tofrom_128.go +65 -0
- package/bin/go/src/simd/internal/bridge/tofrom_amd64.go +123 -0
- package/bin/go/src/simd/internal/bridge/tofrom_emulated.go +63 -0
- package/bin/go/src/simd/midway_amd64.go +34 -0
- package/bin/go/src/simd/midway_arm64.go +22 -0
- package/bin/go/src/simd/midway_common.go +138 -0
- package/bin/go/src/simd/midway_wasm.go +13 -0
- package/bin/go/src/simd/simd_emulated.go +3275 -0
- package/bin/go/src/simd/simd_stubs.go +1041 -0
- package/bin/go/src/simd/simd_types.go +96 -0
- package/bin/go/src/simd/tofrom_amd64.go +374 -0
- package/bin/go/src/simd/tofrom_arm64.go +290 -0
- package/bin/go/src/simd/tofrom_wasm.go +290 -0
- package/bin/go/src/slices/slices.go +9 -7
- package/bin/go/src/strconv/isprint.go +81 -51
- package/bin/go/src/strings/builder.go +1 -1
- package/bin/go/src/strings/strings.go +44 -35
- package/bin/go/src/sync/atomic/doc.go +7 -0
- package/bin/go/src/sync/cond.go +4 -2
- package/bin/go/src/sync/pool.go +6 -15
- package/bin/go/src/sync/runtime2_lockrank.go +1 -2
- package/bin/go/src/syscall/exec_bsd.go +3 -3
- package/bin/go/src/syscall/exec_libc2.go +1 -1
- package/bin/go/src/syscall/exec_linux.go +7 -2
- package/bin/go/src/syscall/fs_js.go +9 -4
- package/bin/go/src/syscall/fs_wasip1.go +6 -0
- package/bin/go/src/syscall/js/js.go +2 -2
- package/bin/go/src/syscall/linkname_bsd.go +8 -0
- package/bin/go/src/syscall/linkname_libc.go +1 -1
- package/bin/go/src/syscall/linkname_openbsd.go +0 -2
- package/bin/go/src/syscall/mkall.sh +6 -17
- package/bin/go/src/syscall/syscall_aix.go +5 -0
- package/bin/go/src/syscall/syscall_linux_386.go +9 -0
- package/bin/go/src/syscall/syscall_linux_amd64.go +5 -0
- package/bin/go/src/syscall/syscall_linux_arm.go +4 -0
- package/bin/go/src/syscall/syscall_linux_arm64.go +3 -0
- package/bin/go/src/syscall/syscall_linux_loong64.go +3 -0
- package/bin/go/src/syscall/syscall_linux_mipsx.go +4 -0
- package/bin/go/src/syscall/syscall_linux_riscv64.go +3 -0
- package/bin/go/src/syscall/syscall_linux_s390x.go +5 -0
- package/bin/go/src/syscall/syscall_openbsd.go +77 -2
- package/bin/go/src/syscall/syscall_plan9.go +25 -0
- package/bin/go/src/syscall/syscall_solaris.go +11 -0
- package/bin/go/src/syscall/syscall_unix.go +19 -0
- package/bin/go/src/syscall/syscall_windows.go +1 -1
- package/bin/go/src/testing/synctest/synctest.go +21 -0
- package/bin/go/src/testing/testing.go +211 -52
- package/bin/go/src/text/template/parse/lex.go +6 -6
- package/bin/go/src/text/template/parse/node.go +21 -16
- package/bin/go/src/text/template/parse/parse.go +23 -6
- package/bin/go/src/text/template/template.go +5 -3
- package/bin/go/src/time/format.go +3 -0
- package/bin/go/src/time/sleep.go +0 -33
- package/bin/go/src/time/tick.go +3 -2
- package/bin/go/src/time/time.go +2 -2
- package/bin/go/src/time/tzdata/zzipdata.go +1 -1
- package/bin/go/src/time/zoneinfo.go +5 -4
- package/bin/go/src/time/zoneinfo_read.go +1 -1
- package/bin/go/src/unicode/tables.go +898 -417
- package/bin/go/src/uuid/uuid.go +273 -0
- package/bin/go/src/vendor/golang.org/x/crypto/chacha20poly1305/chacha20poly1305_amd64.go +3 -3
- package/bin/go/src/vendor/golang.org/x/crypto/chacha20poly1305/chacha20poly1305_amd64.s +2066 -6598
- package/bin/go/src/vendor/golang.org/x/crypto/hkdf/hkdf.go +100 -0
- package/bin/go/src/vendor/golang.org/x/net/dns/dnsmessage/message.go +5 -4
- package/bin/go/src/vendor/golang.org/x/net/http/httpproxy/proxy.go +4 -4
- package/bin/go/src/vendor/golang.org/x/net/http3/http3.go +46 -0
- package/bin/go/src/vendor/golang.org/x/net/idna/{idna10.0.0.go → idna.go} +133 -35
- package/bin/go/src/vendor/golang.org/x/net/idna/punycode.go +4 -1
- package/bin/go/src/vendor/golang.org/x/net/idna/tables15.0.0.go +1 -1
- package/bin/go/src/vendor/golang.org/x/net/idna/tables17.0.0.go +5302 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/body.go +231 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/conn.go +131 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/doc.go +10 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/errors.go +102 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/http3.go +95 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/qpack.go +356 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/qpack_decode.go +81 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/qpack_encode.go +61 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/qpack_static.go +142 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/quic.go +40 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/roundtrip.go +423 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/server.go +866 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/settings.go +66 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/stream.go +260 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/transport.go +333 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/http3/varint.go +23 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/httpcommon/ascii.go +53 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/httpcommon/headermap.go +115 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/httpcommon/request.go +475 -0
- package/bin/go/src/vendor/golang.org/x/net/internal/quic/quicwire/wire.go +150 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/ack_delay.go +26 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/acks.go +213 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/atomic_bits.go +31 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/config.go +158 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/congestion_reno.go +306 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/conn.go +434 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/conn_close.go +340 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/conn_flow.go +142 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/conn_id.go +502 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/conn_loss.go +85 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/conn_recv.go +631 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/conn_send.go +407 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/conn_streams.go +483 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/crypto_stream.go +157 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/dgram.go +53 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/doc.go +50 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/endpoint.go +478 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/errors.go +129 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/frame_debug.go +730 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/gate.go +86 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/idle.go +168 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/log.go +67 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/loss.go +521 -0
- package/bin/go/src/{runtime/cgo/gcc_stack_windows.c → vendor/golang.org/x/net/quic/math.go} +7 -2
- package/bin/go/src/vendor/golang.org/x/net/quic/pacer.go +129 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/packet.go +267 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/packet_number.go +72 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/packet_parser.go +519 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/packet_protection.go +539 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/packet_writer.go +566 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/path.go +87 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/ping.go +14 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/pipe.go +173 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/qlog.go +272 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/queue.go +63 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/quic.go +221 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/race_disabled.go +10 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/race_enabled.go +27 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/rangeset.go +193 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/retry.go +240 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/rtt.go +71 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/sent_packet.go +119 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/sent_packet_list.go +93 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/sent_val.go +103 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/skip.go +62 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/stateless_reset.go +59 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/stream.go +1106 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/stream_limits.go +138 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/tls.go +123 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/transport_params.go +283 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/udp.go +28 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/udp_darwin.go +45 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/udp_linux.go +39 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/udp_msg.go +245 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/udp_other.go +62 -0
- package/bin/go/src/vendor/golang.org/x/net/quic/udp_packetconn.go +67 -0
- package/bin/go/src/vendor/golang.org/x/sys/cpu/asm_darwin_arm64_gc.s +12 -0
- package/bin/go/src/vendor/golang.org/x/sys/cpu/cpu.go +12 -7
- package/bin/go/src/vendor/golang.org/x/sys/cpu/cpu_arm64.go +3 -6
- package/bin/go/src/vendor/golang.org/x/sys/cpu/cpu_darwin_arm64.go +67 -0
- package/bin/go/src/vendor/golang.org/x/sys/cpu/cpu_darwin_arm64_other.go +31 -0
- package/bin/go/src/vendor/golang.org/x/sys/cpu/cpu_gccgo_arm64.go +1 -0
- package/bin/go/src/vendor/golang.org/x/sys/cpu/cpu_linux_riscv64.go +2 -0
- package/bin/go/src/vendor/golang.org/x/sys/cpu/cpu_loong64.go +14 -2
- package/bin/go/src/vendor/golang.org/x/sys/cpu/cpu_other_arm64.go +4 -2
- package/bin/go/src/vendor/golang.org/x/sys/cpu/cpu_riscv64.go +1 -0
- package/bin/go/src/vendor/golang.org/x/sys/cpu/cpu_windows.go +26 -0
- package/bin/go/src/vendor/golang.org/x/sys/cpu/cpu_windows_arm64.go +38 -0
- package/bin/go/src/vendor/golang.org/x/sys/cpu/cpu_x86.go +124 -50
- package/bin/go/src/vendor/golang.org/x/sys/cpu/syscall_darwin_arm64_gc.go +54 -0
- package/bin/go/src/vendor/golang.org/x/sys/cpu/zcpu_windows.go +48 -0
- package/bin/go/src/vendor/golang.org/x/text/secure/bidirule/bidirule.go +4 -0
- package/bin/go/src/vendor/golang.org/x/text/unicode/bidi/tables15.0.0.go +1 -1
- package/bin/go/src/vendor/golang.org/x/text/unicode/bidi/tables17.0.0.go +2135 -0
- package/bin/go/src/vendor/golang.org/x/text/unicode/norm/forminfo.go +18 -8
- package/bin/go/src/vendor/golang.org/x/text/unicode/norm/tables15.0.0.go +1410 -1410
- package/bin/go/src/vendor/golang.org/x/text/unicode/norm/{tables13.0.0.go → tables17.0.0.go} +3530 -3186
- package/bin/go/src/vendor/modules.txt +14 -8
- package/bin/ttsc-cache.exe +0 -0
- package/bin/ttsc.exe +0 -0
- package/bin/ttscserver.exe +0 -0
- package/package.json +1 -1
- package/bin/go/src/crypto/internal/fips140/nistec/p256_ordinv_noasm.go +0 -13
- package/bin/go/src/go/internal/scannerhooks/hooks.go +0 -11
- package/bin/go/src/hash/maphash/maphash_purego.go +0 -200
- package/bin/go/src/hash/maphash/maphash_runtime.go +0 -64
- package/bin/go/src/internal/goexperiment/exp_goroutineleakprofile_off.go +0 -8
- package/bin/go/src/internal/goexperiment/exp_goroutineleakprofile_on.go +0 -8
- package/bin/go/src/internal/strconv/atofeisel.go +0 -166
- package/bin/go/src/internal/strconv/ftoadbox.go +0 -349
- package/bin/go/src/internal/strconv/ftoafixed.go +0 -184
- package/bin/go/src/internal/strconv/math.go +0 -179
- package/bin/go/src/net/http/h2_bundle.go +0 -12371
- package/bin/go/src/net/http/h2_error.go +0 -37
- package/bin/go/src/runtime/cgo/gcc_darwin_amd64.c +0 -61
- package/bin/go/src/runtime/cgo/gcc_darwin_arm64.c +0 -148
- package/bin/go/src/runtime/cgo/gcc_dragonfly_amd64.c +0 -61
- package/bin/go/src/runtime/cgo/gcc_freebsd.c +0 -72
- package/bin/go/src/runtime/cgo/gcc_freebsd_amd64.c +0 -72
- package/bin/go/src/runtime/cgo/gcc_linux.c +0 -67
- package/bin/go/src/runtime/cgo/gcc_linux_amd64.c +0 -92
- package/bin/go/src/runtime/cgo/gcc_linux_arm64.c +0 -88
- package/bin/go/src/runtime/cgo/gcc_linux_s390x.c +0 -64
- package/bin/go/src/runtime/cgo/gcc_openbsd.c +0 -62
- package/bin/go/src/runtime/cgo/gcc_ppc64x.c +0 -68
- package/bin/go/src/runtime/cgo/gcc_signal2_ios_arm64.c +0 -11
- package/bin/go/src/runtime/cgo/gcc_signal_ios_arm64.c +0 -213
- package/bin/go/src/runtime/cgo/gcc_signal_ios_nolldb.c +0 -10
- package/bin/go/src/runtime/cgo/gcc_solaris_amd64.c +0 -83
- package/bin/go/src/runtime/cgo/gcc_stack_darwin.c +0 -25
- package/bin/go/src/runtime/cgo/gcc_stack_unix.c +0 -48
- package/bin/go/src/runtime/cgo/gcc_windows_386.c +0 -55
- package/bin/go/src/runtime/cgo/gcc_windows_amd64.c +0 -54
- package/bin/go/src/runtime/cgo/gcc_windows_arm64.c +0 -42
- package/bin/go/src/runtime/cgo/libcgo_windows.h +0 -6
- package/bin/go/src/runtime/cgo/signal_ios_arm64.go +0 -10
- package/bin/go/src/runtime/cgo/signal_ios_arm64.s +0 -56
- package/bin/go/src/runtime/rt0_linux_ppc64.s +0 -28
- package/bin/go/src/runtime/stubs_ppc64.go +0 -12
- package/bin/go/src/simd/archsimd/_gen/simdgen/go.yaml +0 -1
- package/bin/go/src/simd/archsimd/_gen/simdgen/ops/ShiftRotate/go.yaml +0 -172
- package/bin/go/src/syscall/asm_openbsd_mips64.s +0 -129
- package/bin/go/src/syscall/syscall_openbsd1.go +0 -12
- package/bin/go/src/syscall/syscall_openbsd_libc.go +0 -84
- package/bin/go/src/syscall/syscall_openbsd_mips64.go +0 -43
- package/bin/go/src/syscall/zerrors_openbsd_mips64.go +0 -1682
- package/bin/go/src/syscall/zsyscall_openbsd_mips64.go +0 -1289
- package/bin/go/src/syscall/zsysnum_openbsd_mips64.go +0 -218
- package/bin/go/src/syscall/ztypes_openbsd_mips64.go +0 -443
- package/bin/go/src/vendor/golang.org/x/net/idna/go118.go +0 -13
- package/bin/go/src/vendor/golang.org/x/net/idna/idna9.0.0.go +0 -717
- package/bin/go/src/vendor/golang.org/x/net/idna/pre_go118.go +0 -11
- package/bin/go/src/vendor/golang.org/x/net/idna/tables10.0.0.go +0 -4559
- package/bin/go/src/vendor/golang.org/x/net/idna/tables11.0.0.go +0 -4653
- package/bin/go/src/vendor/golang.org/x/net/idna/tables12.0.0.go +0 -4733
- package/bin/go/src/vendor/golang.org/x/net/idna/tables13.0.0.go +0 -4959
- package/bin/go/src/vendor/golang.org/x/net/idna/tables9.0.0.go +0 -4486
- package/bin/go/src/vendor/golang.org/x/net/idna/trie12.0.0.go +0 -30
- package/bin/go/src/vendor/golang.org/x/net/idna/trie13.0.0.go +0 -30
- package/bin/go/src/vendor/golang.org/x/text/secure/bidirule/bidirule10.0.0.go +0 -11
- package/bin/go/src/vendor/golang.org/x/text/secure/bidirule/bidirule9.0.0.go +0 -14
- package/bin/go/src/vendor/golang.org/x/text/unicode/bidi/tables10.0.0.go +0 -1815
- package/bin/go/src/vendor/golang.org/x/text/unicode/bidi/tables11.0.0.go +0 -1887
- package/bin/go/src/vendor/golang.org/x/text/unicode/bidi/tables12.0.0.go +0 -1923
- package/bin/go/src/vendor/golang.org/x/text/unicode/bidi/tables13.0.0.go +0 -1955
- package/bin/go/src/vendor/golang.org/x/text/unicode/bidi/tables9.0.0.go +0 -1781
- package/bin/go/src/vendor/golang.org/x/text/unicode/norm/tables10.0.0.go +0 -7657
- package/bin/go/src/vendor/golang.org/x/text/unicode/norm/tables11.0.0.go +0 -7693
- package/bin/go/src/vendor/golang.org/x/text/unicode/norm/tables12.0.0.go +0 -7710
- package/bin/go/src/vendor/golang.org/x/text/unicode/norm/tables9.0.0.go +0 -7637
- /package/bin/go/src/simd/archsimd/_gen/simdgen/ops/BitwiseLogic/{go.yaml → go_amd64.yaml} +0 -0
- /package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Compares/{go.yaml → go_amd64.yaml} +0 -0
- /package/bin/go/src/simd/archsimd/_gen/simdgen/ops/MinMax/{go.yaml → go_amd64.yaml} +0 -0
- /package/bin/go/src/simd/archsimd/_gen/simdgen/ops/Others/{go.yaml → go_amd64.yaml} +0 -0
|
@@ -23,7 +23,7 @@ are generally of the form:
|
|
|
23
23
|
func f(x *operand, e *ast.Expr, ...)
|
|
24
24
|
|
|
25
25
|
where e is the expression to be checked, and x is the result of the check.
|
|
26
|
-
The check performed by f may fail in which case x.
|
|
26
|
+
The check performed by f may fail in which case x.mode_ == invalid, and
|
|
27
27
|
related error messages will have been issued by f.
|
|
28
28
|
|
|
29
29
|
If a hint argument is present, it is the composite literal element type
|
|
@@ -72,7 +72,7 @@ func init() {
|
|
|
72
72
|
|
|
73
73
|
func (check *Checker) op(m opPredicates, x *operand, op token.Token) bool {
|
|
74
74
|
if pred := m[op]; pred != nil {
|
|
75
|
-
if !pred(x.typ) {
|
|
75
|
+
if !pred(x.typ()) {
|
|
76
76
|
check.errorf(x, UndefinedOp, invalidOp+"operator %s not defined on %s", op, x)
|
|
77
77
|
return false
|
|
78
78
|
}
|
|
@@ -128,7 +128,7 @@ var op2str2 = [...]string{
|
|
|
128
128
|
// The unary expression e may be nil. It's passed in for better error messages only.
|
|
129
129
|
func (check *Checker) unary(x *operand, e *ast.UnaryExpr) {
|
|
130
130
|
check.expr(nil, x, e.X)
|
|
131
|
-
if x.
|
|
131
|
+
if !x.isValid() {
|
|
132
132
|
return
|
|
133
133
|
}
|
|
134
134
|
|
|
@@ -137,30 +137,31 @@ func (check *Checker) unary(x *operand, e *ast.UnaryExpr) {
|
|
|
137
137
|
case token.AND:
|
|
138
138
|
// spec: "As an exception to the addressability
|
|
139
139
|
// requirement x may also be a composite literal."
|
|
140
|
-
if _, ok := ast.Unparen(e.X).(*ast.CompositeLit); !ok && x.mode != variable {
|
|
140
|
+
if _, ok := ast.Unparen(e.X).(*ast.CompositeLit); !ok && x.mode() != variable {
|
|
141
141
|
check.errorf(x, UnaddressableOperand, invalidOp+"cannot take address of %s", x)
|
|
142
|
-
x.
|
|
142
|
+
x.invalidate()
|
|
143
143
|
return
|
|
144
144
|
}
|
|
145
|
-
x.
|
|
146
|
-
x.
|
|
145
|
+
x.mode_ = value
|
|
146
|
+
x.typ_ = &Pointer{base: x.typ()}
|
|
147
147
|
return
|
|
148
148
|
|
|
149
149
|
case token.ARROW:
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
x.
|
|
150
|
+
// We cannot receive a value with an incomplete type; make sure it's complete.
|
|
151
|
+
if elem := check.chanElem(x, x, true); elem != nil && check.isComplete(elem) {
|
|
152
|
+
x.mode_ = commaok
|
|
153
|
+
x.typ_ = elem
|
|
153
154
|
check.hasCallOrRecv = true
|
|
154
155
|
return
|
|
155
156
|
}
|
|
156
|
-
x.
|
|
157
|
+
x.invalidate()
|
|
157
158
|
return
|
|
158
159
|
|
|
159
160
|
case token.TILDE:
|
|
160
161
|
// Provide a better error position and message than what check.op below would do.
|
|
161
|
-
if !allInteger(x.typ) {
|
|
162
|
+
if !allInteger(x.typ()) {
|
|
162
163
|
check.error(e, UndefinedOp, "cannot use ~ outside of interface or type constraint")
|
|
163
|
-
x.
|
|
164
|
+
x.invalidate()
|
|
164
165
|
return
|
|
165
166
|
}
|
|
166
167
|
check.error(e, UndefinedOp, "cannot use ~ outside of interface or type constraint (use ^ for bitwise complement)")
|
|
@@ -168,18 +169,18 @@ func (check *Checker) unary(x *operand, e *ast.UnaryExpr) {
|
|
|
168
169
|
}
|
|
169
170
|
|
|
170
171
|
if !check.op(unaryOpPredicates, x, op) {
|
|
171
|
-
x.
|
|
172
|
+
x.invalidate()
|
|
172
173
|
return
|
|
173
174
|
}
|
|
174
175
|
|
|
175
|
-
if x.mode == constant_ {
|
|
176
|
+
if x.mode() == constant_ {
|
|
176
177
|
if x.val.Kind() == constant.Unknown {
|
|
177
178
|
// nothing to do (and don't cause an error below in the overflow check)
|
|
178
179
|
return
|
|
179
180
|
}
|
|
180
181
|
var prec uint
|
|
181
|
-
if isUnsigned(x.typ) {
|
|
182
|
-
prec = uint(check.conf.sizeof(x.typ) * 8)
|
|
182
|
+
if isUnsigned(x.typ()) {
|
|
183
|
+
prec = uint(check.conf.sizeof(x.typ()) * 8)
|
|
183
184
|
}
|
|
184
185
|
x.val = constant.UnaryOp(op, x.val, prec)
|
|
185
186
|
x.expr = e
|
|
@@ -187,7 +188,7 @@ func (check *Checker) unary(x *operand, e *ast.UnaryExpr) {
|
|
|
187
188
|
return
|
|
188
189
|
}
|
|
189
190
|
|
|
190
|
-
x.
|
|
191
|
+
x.mode_ = value
|
|
191
192
|
// x.typ remains unchanged
|
|
192
193
|
}
|
|
193
194
|
|
|
@@ -195,7 +196,7 @@ func (check *Checker) unary(x *operand, e *ast.UnaryExpr) {
|
|
|
195
196
|
// or send to x (recv == false) operation. If the operation is not valid, chanElem
|
|
196
197
|
// reports an error and returns nil.
|
|
197
198
|
func (check *Checker) chanElem(pos positioner, x *operand, recv bool) Type {
|
|
198
|
-
u, err := commonUnder(x.typ, func(t, u Type) *typeError {
|
|
199
|
+
u, err := commonUnder(x.typ(), func(t, u Type) *typeError {
|
|
199
200
|
if u == nil {
|
|
200
201
|
return typeErrorf("no specific channel type")
|
|
201
202
|
}
|
|
@@ -218,14 +219,14 @@ func (check *Checker) chanElem(pos positioner, x *operand, recv bool) Type {
|
|
|
218
219
|
|
|
219
220
|
cause := err.format(check)
|
|
220
221
|
if recv {
|
|
221
|
-
if isTypeParam(x.typ) {
|
|
222
|
+
if isTypeParam(x.typ()) {
|
|
222
223
|
check.errorf(pos, InvalidReceive, invalidOp+"cannot receive from %s: %s", x, cause)
|
|
223
224
|
} else {
|
|
224
225
|
// In this case, only the non-channel and send-only channel error are possible.
|
|
225
226
|
check.errorf(pos, InvalidReceive, invalidOp+"cannot receive from %s %s", cause, x)
|
|
226
227
|
}
|
|
227
228
|
} else {
|
|
228
|
-
if isTypeParam(x.typ) {
|
|
229
|
+
if isTypeParam(x.typ()) {
|
|
229
230
|
check.errorf(pos, InvalidSend, invalidOp+"cannot send to %s: %s", x, cause)
|
|
230
231
|
} else {
|
|
231
232
|
// In this case, only the non-channel and receive-only channel error are possible.
|
|
@@ -361,7 +362,7 @@ func (check *Checker) updateExprType(x ast.Expr, typ Type, final bool) {
|
|
|
361
362
|
// If x is a constant, it must be representable as a value of typ.
|
|
362
363
|
c := operand{old.mode, x, old.typ, old.val, 0}
|
|
363
364
|
check.convertUntyped(&c, typ)
|
|
364
|
-
if c.
|
|
365
|
+
if !c.isValid() {
|
|
365
366
|
return
|
|
366
367
|
}
|
|
367
368
|
}
|
|
@@ -385,14 +386,14 @@ func (check *Checker) updateExprVal(x ast.Expr, val constant.Value) {
|
|
|
385
386
|
// If x is a constant operand, the returned constant.Value will be the
|
|
386
387
|
// representation of x in this context.
|
|
387
388
|
func (check *Checker) implicitTypeAndValue(x *operand, target Type) (Type, constant.Value, Code) {
|
|
388
|
-
if x.
|
|
389
|
-
return x.typ, nil, 0
|
|
389
|
+
if !x.isValid() || isTyped(x.typ()) || !isValid(target) {
|
|
390
|
+
return x.typ(), nil, 0
|
|
390
391
|
}
|
|
391
392
|
// x is untyped
|
|
392
393
|
|
|
393
394
|
if isUntyped(target) {
|
|
394
395
|
// both x and target are untyped
|
|
395
|
-
if m := maxType(x.typ, target); m != nil {
|
|
396
|
+
if m := maxType(x.typ(), target); m != nil {
|
|
396
397
|
return m, nil, 0
|
|
397
398
|
}
|
|
398
399
|
return nil, nil, InvalidUntypedConversion
|
|
@@ -400,7 +401,7 @@ func (check *Checker) implicitTypeAndValue(x *operand, target Type) (Type, const
|
|
|
400
401
|
|
|
401
402
|
switch u := target.Underlying().(type) {
|
|
402
403
|
case *Basic:
|
|
403
|
-
if x.mode == constant_ {
|
|
404
|
+
if x.mode() == constant_ {
|
|
404
405
|
v, code := check.representation(x, u)
|
|
405
406
|
if code != 0 {
|
|
406
407
|
return nil, nil, code
|
|
@@ -411,7 +412,7 @@ func (check *Checker) implicitTypeAndValue(x *operand, target Type) (Type, const
|
|
|
411
412
|
// result of comparisons (untyped bool), intermediate
|
|
412
413
|
// (delayed-checked) rhs operands of shifts, and as
|
|
413
414
|
// the value nil.
|
|
414
|
-
switch x.typ.(*Basic).kind {
|
|
415
|
+
switch x.typ().(*Basic).kind {
|
|
415
416
|
case UntypedBool:
|
|
416
417
|
if !isBoolean(target) {
|
|
417
418
|
return nil, nil, InvalidUntypedConversion
|
|
@@ -465,7 +466,7 @@ func (check *Checker) implicitTypeAndValue(x *operand, target Type) (Type, const
|
|
|
465
466
|
if !u.Empty() {
|
|
466
467
|
return nil, nil, InvalidUntypedConversion
|
|
467
468
|
}
|
|
468
|
-
return Default(x.typ), nil, 0
|
|
469
|
+
return Default(x.typ()), nil, 0
|
|
469
470
|
case *Pointer, *Signature, *Slice, *Map, *Chan:
|
|
470
471
|
if !x.isNil() {
|
|
471
472
|
return nil, nil, InvalidUntypedConversion
|
|
@@ -481,8 +482,8 @@ func (check *Checker) implicitTypeAndValue(x *operand, target Type) (Type, const
|
|
|
481
482
|
// If switchCase is true, the operator op is ignored.
|
|
482
483
|
func (check *Checker) comparison(x, y *operand, op token.Token, switchCase bool) {
|
|
483
484
|
// Avoid spurious errors if any of the operands has an invalid type (go.dev/issue/54405).
|
|
484
|
-
if !isValid(x.typ) || !isValid(y.typ) {
|
|
485
|
-
x.
|
|
485
|
+
if !isValid(x.typ()) || !isValid(y.typ()) {
|
|
486
|
+
x.invalidate()
|
|
486
487
|
return
|
|
487
488
|
}
|
|
488
489
|
|
|
@@ -496,16 +497,16 @@ func (check *Checker) comparison(x, y *operand, op token.Token, switchCase bool)
|
|
|
496
497
|
// spec: "In any comparison, the first operand must be assignable
|
|
497
498
|
// to the type of the second operand, or vice versa."
|
|
498
499
|
code := MismatchedTypes
|
|
499
|
-
ok, _ := x.assignableTo(check, y.typ, nil)
|
|
500
|
+
ok, _ := x.assignableTo(check, y.typ(), nil)
|
|
500
501
|
if !ok {
|
|
501
|
-
ok, _ = y.assignableTo(check, x.typ, nil)
|
|
502
|
+
ok, _ = y.assignableTo(check, x.typ(), nil)
|
|
502
503
|
}
|
|
503
504
|
if !ok {
|
|
504
505
|
// Report the error on the 2nd operand since we only
|
|
505
506
|
// know after seeing the 2nd operand whether we have
|
|
506
507
|
// a type mismatch.
|
|
507
508
|
errOp = y
|
|
508
|
-
cause = check.sprintf("mismatched types %s and %s", x.typ, y.typ)
|
|
509
|
+
cause = check.sprintf("mismatched types %s and %s", x.typ(), y.typ())
|
|
509
510
|
goto Error
|
|
510
511
|
}
|
|
511
512
|
|
|
@@ -517,9 +518,9 @@ func (check *Checker) comparison(x, y *operand, op token.Token, switchCase bool)
|
|
|
517
518
|
switch {
|
|
518
519
|
case x.isNil() || y.isNil():
|
|
519
520
|
// Comparison against nil requires that the other operand type has nil.
|
|
520
|
-
typ := x.typ
|
|
521
|
+
typ := x.typ()
|
|
521
522
|
if x.isNil() {
|
|
522
|
-
typ = y.typ
|
|
523
|
+
typ = y.typ()
|
|
523
524
|
}
|
|
524
525
|
if !hasNil(typ) {
|
|
525
526
|
// This case should only be possible for "nil == nil".
|
|
@@ -530,24 +531,24 @@ func (check *Checker) comparison(x, y *operand, op token.Token, switchCase bool)
|
|
|
530
531
|
goto Error
|
|
531
532
|
}
|
|
532
533
|
|
|
533
|
-
case !Comparable(x.typ):
|
|
534
|
+
case !Comparable(x.typ()):
|
|
534
535
|
errOp = x
|
|
535
|
-
cause = check.incomparableCause(x.typ)
|
|
536
|
+
cause = check.incomparableCause(x.typ())
|
|
536
537
|
goto Error
|
|
537
538
|
|
|
538
|
-
case !Comparable(y.typ):
|
|
539
|
+
case !Comparable(y.typ()):
|
|
539
540
|
errOp = y
|
|
540
|
-
cause = check.incomparableCause(y.typ)
|
|
541
|
+
cause = check.incomparableCause(y.typ())
|
|
541
542
|
goto Error
|
|
542
543
|
}
|
|
543
544
|
|
|
544
545
|
case token.LSS, token.LEQ, token.GTR, token.GEQ:
|
|
545
546
|
// spec: The ordering operators <, <=, >, and >= apply to operands that are ordered."
|
|
546
547
|
switch {
|
|
547
|
-
case !allOrdered(x.typ):
|
|
548
|
+
case !allOrdered(x.typ()):
|
|
548
549
|
errOp = x
|
|
549
550
|
goto Error
|
|
550
|
-
case !allOrdered(y.typ):
|
|
551
|
+
case !allOrdered(y.typ()):
|
|
551
552
|
errOp = y
|
|
552
553
|
goto Error
|
|
553
554
|
}
|
|
@@ -557,39 +558,39 @@ func (check *Checker) comparison(x, y *operand, op token.Token, switchCase bool)
|
|
|
557
558
|
}
|
|
558
559
|
|
|
559
560
|
// comparison is ok
|
|
560
|
-
if x.mode == constant_ && y.mode == constant_ {
|
|
561
|
+
if x.mode() == constant_ && y.mode() == constant_ {
|
|
561
562
|
x.val = constant.MakeBool(constant.Compare(x.val, op, y.val))
|
|
562
563
|
// The operands are never materialized; no need to update
|
|
563
564
|
// their types.
|
|
564
565
|
} else {
|
|
565
|
-
x.
|
|
566
|
+
x.mode_ = value
|
|
566
567
|
// The operands have now their final types, which at run-
|
|
567
568
|
// time will be materialized. Update the expression trees.
|
|
568
569
|
// If the current types are untyped, the materialized type
|
|
569
570
|
// is the respective default type.
|
|
570
|
-
check.updateExprType(x.expr, Default(x.typ), true)
|
|
571
|
-
check.updateExprType(y.expr, Default(y.typ), true)
|
|
571
|
+
check.updateExprType(x.expr, Default(x.typ()), true)
|
|
572
|
+
check.updateExprType(y.expr, Default(y.typ()), true)
|
|
572
573
|
}
|
|
573
574
|
|
|
574
575
|
// spec: "Comparison operators compare two operands and yield
|
|
575
576
|
// an untyped boolean value."
|
|
576
|
-
x.
|
|
577
|
+
x.typ_ = Typ[UntypedBool]
|
|
577
578
|
return
|
|
578
579
|
|
|
579
580
|
Error:
|
|
580
581
|
// We have an offending operand errOp and possibly an error cause.
|
|
581
582
|
if cause == "" {
|
|
582
|
-
if isTypeParam(x.typ) || isTypeParam(y.typ) {
|
|
583
|
+
if isTypeParam(x.typ()) || isTypeParam(y.typ()) {
|
|
583
584
|
// TODO(gri) should report the specific type causing the problem, if any
|
|
584
|
-
if !isTypeParam(x.typ) {
|
|
585
|
+
if !isTypeParam(x.typ()) {
|
|
585
586
|
errOp = y
|
|
586
587
|
}
|
|
587
|
-
cause = check.sprintf("type parameter %s cannot use operator %s", errOp.typ, op)
|
|
588
|
+
cause = check.sprintf("type parameter %s cannot use operator %s", errOp.typ(), op)
|
|
588
589
|
} else {
|
|
589
590
|
// catch-all neither x nor y is a type parameter
|
|
590
|
-
what := compositeKind(errOp.typ)
|
|
591
|
+
what := compositeKind(errOp.typ())
|
|
591
592
|
if what == "" {
|
|
592
|
-
what = check.sprintf("%s", errOp.typ)
|
|
593
|
+
what = check.sprintf("%s", errOp.typ())
|
|
593
594
|
}
|
|
594
595
|
cause = check.sprintf("operator %s not defined on %s", op, what)
|
|
595
596
|
}
|
|
@@ -599,7 +600,7 @@ Error:
|
|
|
599
600
|
} else {
|
|
600
601
|
check.errorf(errOp, code, invalidOp+"%s %s %s (%s)", x.expr, op, y.expr, cause)
|
|
601
602
|
}
|
|
602
|
-
x.
|
|
603
|
+
x.invalidate()
|
|
603
604
|
}
|
|
604
605
|
|
|
605
606
|
// incomparableCause returns a more specific cause why typ is not comparable.
|
|
@@ -618,17 +619,17 @@ func (check *Checker) shift(x, y *operand, e ast.Expr, op token.Token) {
|
|
|
618
619
|
// TODO(gri) This function seems overly complex. Revisit.
|
|
619
620
|
|
|
620
621
|
var xval constant.Value
|
|
621
|
-
if x.mode == constant_ {
|
|
622
|
+
if x.mode() == constant_ {
|
|
622
623
|
xval = constant.ToInt(x.val)
|
|
623
624
|
}
|
|
624
625
|
|
|
625
|
-
if allInteger(x.typ) || isUntyped(x.typ) && xval != nil && xval.Kind() == constant.Int {
|
|
626
|
+
if allInteger(x.typ()) || isUntyped(x.typ()) && xval != nil && xval.Kind() == constant.Int {
|
|
626
627
|
// The lhs is of integer type or an untyped constant representable
|
|
627
628
|
// as an integer. Nothing to do.
|
|
628
629
|
} else {
|
|
629
630
|
// shift has no chance
|
|
630
631
|
check.errorf(x, InvalidShiftOperand, invalidOp+"shifted operand %s must be integer", x)
|
|
631
|
-
x.
|
|
632
|
+
x.invalidate()
|
|
632
633
|
return
|
|
633
634
|
}
|
|
634
635
|
|
|
@@ -638,55 +639,55 @@ func (check *Checker) shift(x, y *operand, e ast.Expr, op token.Token) {
|
|
|
638
639
|
// Check that constants are representable by uint, but do not convert them
|
|
639
640
|
// (see also go.dev/issue/47243).
|
|
640
641
|
var yval constant.Value
|
|
641
|
-
if y.mode == constant_ {
|
|
642
|
+
if y.mode() == constant_ {
|
|
642
643
|
// Provide a good error message for negative shift counts.
|
|
643
644
|
yval = constant.ToInt(y.val) // consider -1, 1.0, but not -1.1
|
|
644
645
|
if yval.Kind() == constant.Int && constant.Sign(yval) < 0 {
|
|
645
646
|
check.errorf(y, InvalidShiftCount, invalidOp+"negative shift count %s", y)
|
|
646
|
-
x.
|
|
647
|
+
x.invalidate()
|
|
647
648
|
return
|
|
648
649
|
}
|
|
649
650
|
|
|
650
|
-
if isUntyped(y.typ) {
|
|
651
|
+
if isUntyped(y.typ()) {
|
|
651
652
|
// Caution: Check for representability here, rather than in the switch
|
|
652
653
|
// below, because isInteger includes untyped integers (was bug go.dev/issue/43697).
|
|
653
654
|
check.representable(y, Typ[Uint])
|
|
654
|
-
if y.
|
|
655
|
-
x.
|
|
655
|
+
if !y.isValid() {
|
|
656
|
+
x.invalidate()
|
|
656
657
|
return
|
|
657
658
|
}
|
|
658
659
|
}
|
|
659
660
|
} else {
|
|
660
661
|
// Check that RHS is otherwise at least of integer type.
|
|
661
662
|
switch {
|
|
662
|
-
case allInteger(y.typ):
|
|
663
|
-
if !allUnsigned(y.typ) && !check.verifyVersionf(y, go1_13, invalidOp+"signed shift count %s", y) {
|
|
664
|
-
x.
|
|
663
|
+
case allInteger(y.typ()):
|
|
664
|
+
if !allUnsigned(y.typ()) && !check.verifyVersionf(y, go1_13, invalidOp+"signed shift count %s", y) {
|
|
665
|
+
x.invalidate()
|
|
665
666
|
return
|
|
666
667
|
}
|
|
667
|
-
case isUntyped(y.typ):
|
|
668
|
+
case isUntyped(y.typ()):
|
|
668
669
|
// This is incorrect, but preserves pre-existing behavior.
|
|
669
670
|
// See also go.dev/issue/47410.
|
|
670
671
|
check.convertUntyped(y, Typ[Uint])
|
|
671
|
-
if y.
|
|
672
|
-
x.
|
|
672
|
+
if !y.isValid() {
|
|
673
|
+
x.invalidate()
|
|
673
674
|
return
|
|
674
675
|
}
|
|
675
676
|
default:
|
|
676
677
|
check.errorf(y, InvalidShiftCount, invalidOp+"shift count %s must be integer", y)
|
|
677
|
-
x.
|
|
678
|
+
x.invalidate()
|
|
678
679
|
return
|
|
679
680
|
}
|
|
680
681
|
}
|
|
681
682
|
|
|
682
|
-
if x.mode == constant_ {
|
|
683
|
-
if y.mode == constant_ {
|
|
683
|
+
if x.mode() == constant_ {
|
|
684
|
+
if y.mode() == constant_ {
|
|
684
685
|
// if either x or y has an unknown value, the result is unknown
|
|
685
686
|
if x.val.Kind() == constant.Unknown || y.val.Kind() == constant.Unknown {
|
|
686
687
|
x.val = constant.MakeUnknown()
|
|
687
688
|
// ensure the correct type - see comment below
|
|
688
|
-
if !isInteger(x.typ) {
|
|
689
|
-
x.
|
|
689
|
+
if !isInteger(x.typ()) {
|
|
690
|
+
x.typ_ = Typ[UntypedInt]
|
|
690
691
|
}
|
|
691
692
|
return
|
|
692
693
|
}
|
|
@@ -695,15 +696,15 @@ func (check *Checker) shift(x, y *operand, e ast.Expr, op token.Token) {
|
|
|
695
696
|
s, ok := constant.Uint64Val(yval)
|
|
696
697
|
if !ok || s > shiftBound {
|
|
697
698
|
check.errorf(y, InvalidShiftCount, invalidOp+"invalid shift count %s", y)
|
|
698
|
-
x.
|
|
699
|
+
x.invalidate()
|
|
699
700
|
return
|
|
700
701
|
}
|
|
701
702
|
// The lhs is representable as an integer but may not be an integer
|
|
702
703
|
// (e.g., 2.0, an untyped float) - this can only happen for untyped
|
|
703
704
|
// non-integer numeric constants. Correct the type so that the shift
|
|
704
705
|
// result is of integer type.
|
|
705
|
-
if !isInteger(x.typ) {
|
|
706
|
-
x.
|
|
706
|
+
if !isInteger(x.typ()) {
|
|
707
|
+
x.typ_ = Typ[UntypedInt]
|
|
707
708
|
}
|
|
708
709
|
// x is a constant so xval != nil and it must be of Int kind.
|
|
709
710
|
x.val = constant.Shift(xval, op, uint(s))
|
|
@@ -713,7 +714,7 @@ func (check *Checker) shift(x, y *operand, e ast.Expr, op token.Token) {
|
|
|
713
714
|
}
|
|
714
715
|
|
|
715
716
|
// non-constant shift with constant lhs
|
|
716
|
-
if isUntyped(x.typ) {
|
|
717
|
+
if isUntyped(x.typ()) {
|
|
717
718
|
// spec: "If the left operand of a non-constant shift
|
|
718
719
|
// expression is an untyped constant, the type of the
|
|
719
720
|
// constant is what it would be if the shift expression
|
|
@@ -738,19 +739,19 @@ func (check *Checker) shift(x, y *operand, e ast.Expr, op token.Token) {
|
|
|
738
739
|
check.untyped[x.expr] = info
|
|
739
740
|
}
|
|
740
741
|
// keep x's type
|
|
741
|
-
x.
|
|
742
|
+
x.mode_ = value
|
|
742
743
|
return
|
|
743
744
|
}
|
|
744
745
|
}
|
|
745
746
|
|
|
746
747
|
// non-constant shift - lhs must be an integer
|
|
747
|
-
if !allInteger(x.typ) {
|
|
748
|
+
if !allInteger(x.typ()) {
|
|
748
749
|
check.errorf(x, InvalidShiftOperand, invalidOp+"shifted operand %s must be integer", x)
|
|
749
|
-
x.
|
|
750
|
+
x.invalidate()
|
|
750
751
|
return
|
|
751
752
|
}
|
|
752
753
|
|
|
753
|
-
x.
|
|
754
|
+
x.mode_ = value
|
|
754
755
|
}
|
|
755
756
|
|
|
756
757
|
var binaryOpPredicates opPredicates
|
|
@@ -782,11 +783,11 @@ func (check *Checker) binary(x *operand, e ast.Expr, lhs, rhs ast.Expr, op token
|
|
|
782
783
|
check.expr(nil, x, lhs)
|
|
783
784
|
check.expr(nil, &y, rhs)
|
|
784
785
|
|
|
785
|
-
if x.
|
|
786
|
+
if !x.isValid() {
|
|
786
787
|
return
|
|
787
788
|
}
|
|
788
|
-
if y.
|
|
789
|
-
x.
|
|
789
|
+
if !y.isValid() {
|
|
790
|
+
x.invalidate()
|
|
790
791
|
x.expr = y.expr
|
|
791
792
|
return
|
|
792
793
|
}
|
|
@@ -797,7 +798,7 @@ func (check *Checker) binary(x *operand, e ast.Expr, lhs, rhs ast.Expr, op token
|
|
|
797
798
|
}
|
|
798
799
|
|
|
799
800
|
check.matchTypes(x, &y)
|
|
800
|
-
if x.
|
|
801
|
+
if !x.isValid() {
|
|
801
802
|
return
|
|
802
803
|
}
|
|
803
804
|
|
|
@@ -806,50 +807,50 @@ func (check *Checker) binary(x *operand, e ast.Expr, lhs, rhs ast.Expr, op token
|
|
|
806
807
|
return
|
|
807
808
|
}
|
|
808
809
|
|
|
809
|
-
if !Identical(x.typ, y.typ) {
|
|
810
|
+
if !Identical(x.typ(), y.typ()) {
|
|
810
811
|
// only report an error if we have valid types
|
|
811
812
|
// (otherwise we had an error reported elsewhere already)
|
|
812
|
-
if isValid(x.typ) && isValid(y.typ) {
|
|
813
|
+
if isValid(x.typ()) && isValid(y.typ()) {
|
|
813
814
|
var posn positioner = x
|
|
814
815
|
if e != nil {
|
|
815
816
|
posn = e
|
|
816
817
|
}
|
|
817
818
|
if e != nil {
|
|
818
|
-
check.errorf(posn, MismatchedTypes, invalidOp+"%s (mismatched types %s and %s)", e, x.typ, y.typ)
|
|
819
|
+
check.errorf(posn, MismatchedTypes, invalidOp+"%s (mismatched types %s and %s)", e, x.typ(), y.typ())
|
|
819
820
|
} else {
|
|
820
|
-
check.errorf(posn, MismatchedTypes, invalidOp+"%s %s= %s (mismatched types %s and %s)", lhs, op, rhs, x.typ, y.typ)
|
|
821
|
+
check.errorf(posn, MismatchedTypes, invalidOp+"%s %s= %s (mismatched types %s and %s)", lhs, op, rhs, x.typ(), y.typ())
|
|
821
822
|
}
|
|
822
823
|
}
|
|
823
|
-
x.
|
|
824
|
+
x.invalidate()
|
|
824
825
|
return
|
|
825
826
|
}
|
|
826
827
|
|
|
827
828
|
if !check.op(binaryOpPredicates, x, op) {
|
|
828
|
-
x.
|
|
829
|
+
x.invalidate()
|
|
829
830
|
return
|
|
830
831
|
}
|
|
831
832
|
|
|
832
833
|
if op == token.QUO || op == token.REM {
|
|
833
834
|
// check for zero divisor
|
|
834
|
-
if (x.mode == constant_ || allInteger(x.typ)) && y.mode == constant_ && constant.Sign(y.val) == 0 {
|
|
835
|
+
if (x.mode() == constant_ || allInteger(x.typ())) && y.mode() == constant_ && constant.Sign(y.val) == 0 {
|
|
835
836
|
check.error(&y, DivByZero, invalidOp+"division by zero")
|
|
836
|
-
x.
|
|
837
|
+
x.invalidate()
|
|
837
838
|
return
|
|
838
839
|
}
|
|
839
840
|
|
|
840
841
|
// check for divisor underflow in complex division (see go.dev/issue/20227)
|
|
841
|
-
if x.mode == constant_ && y.mode == constant_ && isComplex(x.typ) {
|
|
842
|
+
if x.mode() == constant_ && y.mode() == constant_ && isComplex(x.typ()) {
|
|
842
843
|
re, im := constant.Real(y.val), constant.Imag(y.val)
|
|
843
844
|
re2, im2 := constant.BinaryOp(re, token.MUL, re), constant.BinaryOp(im, token.MUL, im)
|
|
844
845
|
if constant.Sign(re2) == 0 && constant.Sign(im2) == 0 {
|
|
845
846
|
check.error(&y, DivByZero, invalidOp+"division by zero")
|
|
846
|
-
x.
|
|
847
|
+
x.invalidate()
|
|
847
848
|
return
|
|
848
849
|
}
|
|
849
850
|
}
|
|
850
851
|
}
|
|
851
852
|
|
|
852
|
-
if x.mode == constant_ && y.mode == constant_ {
|
|
853
|
+
if x.mode() == constant_ && y.mode() == constant_ {
|
|
853
854
|
// if either x or y has an unknown value, the result is unknown
|
|
854
855
|
if x.val.Kind() == constant.Unknown || y.val.Kind() == constant.Unknown {
|
|
855
856
|
x.val = constant.MakeUnknown()
|
|
@@ -857,7 +858,7 @@ func (check *Checker) binary(x *operand, e ast.Expr, lhs, rhs ast.Expr, op token
|
|
|
857
858
|
return
|
|
858
859
|
}
|
|
859
860
|
// force integer division of integer operands
|
|
860
|
-
if op == token.QUO && isInteger(x.typ) {
|
|
861
|
+
if op == token.QUO && isInteger(x.typ()) {
|
|
861
862
|
op = token.QUO_ASSIGN
|
|
862
863
|
}
|
|
863
864
|
x.val = constant.BinaryOp(x.val, op, y.val)
|
|
@@ -866,7 +867,7 @@ func (check *Checker) binary(x *operand, e ast.Expr, lhs, rhs ast.Expr, op token
|
|
|
866
867
|
return
|
|
867
868
|
}
|
|
868
869
|
|
|
869
|
-
x.
|
|
870
|
+
x.mode_ = value
|
|
870
871
|
// x.typ is unchanged
|
|
871
872
|
}
|
|
872
873
|
|
|
@@ -884,51 +885,51 @@ func (check *Checker) matchTypes(x, y *operand) {
|
|
|
884
885
|
// not compatible, we report a type mismatch error.
|
|
885
886
|
mayConvert := func(x, y *operand) bool {
|
|
886
887
|
// If both operands are typed, there's no need for an implicit conversion.
|
|
887
|
-
if isTyped(x.typ) && isTyped(y.typ) {
|
|
888
|
+
if isTyped(x.typ()) && isTyped(y.typ()) {
|
|
888
889
|
return false
|
|
889
890
|
}
|
|
890
891
|
// A numeric type can only convert to another numeric type.
|
|
891
|
-
if allNumeric(x.typ) != allNumeric(y.typ) {
|
|
892
|
+
if allNumeric(x.typ()) != allNumeric(y.typ()) {
|
|
892
893
|
return false
|
|
893
894
|
}
|
|
894
895
|
// An untyped operand may convert to its default type when paired with an empty interface
|
|
895
896
|
// TODO(gri) This should only matter for comparisons (the only binary operation that is
|
|
896
897
|
// valid with interfaces), but in that case the assignability check should take
|
|
897
898
|
// care of the conversion. Verify and possibly eliminate this extra test.
|
|
898
|
-
if isNonTypeParamInterface(x.typ) || isNonTypeParamInterface(y.typ) {
|
|
899
|
+
if isNonTypeParamInterface(x.typ()) || isNonTypeParamInterface(y.typ()) {
|
|
899
900
|
return true
|
|
900
901
|
}
|
|
901
902
|
// A boolean type can only convert to another boolean type.
|
|
902
|
-
if allBoolean(x.typ) != allBoolean(y.typ) {
|
|
903
|
+
if allBoolean(x.typ()) != allBoolean(y.typ()) {
|
|
903
904
|
return false
|
|
904
905
|
}
|
|
905
906
|
// A string type can only convert to another string type.
|
|
906
|
-
if allString(x.typ) != allString(y.typ) {
|
|
907
|
+
if allString(x.typ()) != allString(y.typ()) {
|
|
907
908
|
return false
|
|
908
909
|
}
|
|
909
910
|
// Untyped nil can only convert to a type that has a nil.
|
|
910
911
|
if x.isNil() {
|
|
911
|
-
return hasNil(y.typ)
|
|
912
|
+
return hasNil(y.typ())
|
|
912
913
|
}
|
|
913
914
|
if y.isNil() {
|
|
914
|
-
return hasNil(x.typ)
|
|
915
|
+
return hasNil(x.typ())
|
|
915
916
|
}
|
|
916
917
|
// An untyped operand cannot convert to a pointer.
|
|
917
918
|
// TODO(gri) generalize to type parameters
|
|
918
|
-
if isPointer(x.typ) || isPointer(y.typ) {
|
|
919
|
+
if isPointer(x.typ()) || isPointer(y.typ()) {
|
|
919
920
|
return false
|
|
920
921
|
}
|
|
921
922
|
return true
|
|
922
923
|
}
|
|
923
924
|
|
|
924
925
|
if mayConvert(x, y) {
|
|
925
|
-
check.convertUntyped(x, y.typ)
|
|
926
|
-
if x.
|
|
926
|
+
check.convertUntyped(x, y.typ())
|
|
927
|
+
if !x.isValid() {
|
|
927
928
|
return
|
|
928
929
|
}
|
|
929
|
-
check.convertUntyped(y, x.typ)
|
|
930
|
-
if y.
|
|
931
|
-
x.
|
|
930
|
+
check.convertUntyped(y, x.typ())
|
|
931
|
+
if !y.isValid() {
|
|
932
|
+
x.invalidate()
|
|
932
933
|
return
|
|
933
934
|
}
|
|
934
935
|
}
|
|
@@ -955,8 +956,10 @@ type target struct {
|
|
|
955
956
|
// The result is nil if typ is not a signature.
|
|
956
957
|
func newTarget(typ Type, desc string) *target {
|
|
957
958
|
if typ != nil {
|
|
958
|
-
if
|
|
959
|
-
|
|
959
|
+
if u, _ := commonUnder(typ, nil); u != nil {
|
|
960
|
+
if sig, _ := u.(*Signature); sig != nil {
|
|
961
|
+
return &target{sig, desc}
|
|
962
|
+
}
|
|
960
963
|
}
|
|
961
964
|
}
|
|
962
965
|
return nil
|
|
@@ -985,13 +988,6 @@ func (check *Checker) rawExpr(T *target, x *operand, e ast.Expr, hint Type, allo
|
|
|
985
988
|
check.nonGeneric(T, x)
|
|
986
989
|
}
|
|
987
990
|
|
|
988
|
-
// Here, x is a value, meaning it has a type. If that type is pending, then we have
|
|
989
|
-
// a cycle. As an example:
|
|
990
|
-
//
|
|
991
|
-
// type T [unsafe.Sizeof(T{})]int
|
|
992
|
-
//
|
|
993
|
-
// has a cycle T->T which is deemed valid (by decl.go), but which is in fact invalid.
|
|
994
|
-
check.pendingType(x)
|
|
995
991
|
check.record(x)
|
|
996
992
|
|
|
997
993
|
return kind
|
|
@@ -1001,11 +997,11 @@ func (check *Checker) rawExpr(T *target, x *operand, e ast.Expr, hint Type, allo
|
|
|
1001
997
|
// from a non-nil target T, nonGeneric reports an error and invalidates x.mode and x.typ.
|
|
1002
998
|
// Otherwise it leaves x alone.
|
|
1003
999
|
func (check *Checker) nonGeneric(T *target, x *operand) {
|
|
1004
|
-
if x.
|
|
1000
|
+
if !x.isValid() || x.mode() == novalue {
|
|
1005
1001
|
return
|
|
1006
1002
|
}
|
|
1007
1003
|
var what string
|
|
1008
|
-
switch t := x.typ.(type) {
|
|
1004
|
+
switch t := x.typ().(type) {
|
|
1009
1005
|
case *Alias, *Named:
|
|
1010
1006
|
if isGeneric(t) {
|
|
1011
1007
|
what = "type"
|
|
@@ -1021,21 +1017,8 @@ func (check *Checker) nonGeneric(T *target, x *operand) {
|
|
|
1021
1017
|
}
|
|
1022
1018
|
if what != "" {
|
|
1023
1019
|
check.errorf(x.expr, WrongTypeArgCount, "cannot use generic %s %s without instantiation", what, x.expr)
|
|
1024
|
-
x.
|
|
1025
|
-
x.
|
|
1026
|
-
}
|
|
1027
|
-
}
|
|
1028
|
-
|
|
1029
|
-
// If x has a pending type (i.e. its declaring object is on the object path), pendingType
|
|
1030
|
-
// reports an error and invalidates x.mode and x.typ.
|
|
1031
|
-
// Otherwise it leaves x alone.
|
|
1032
|
-
func (check *Checker) pendingType(x *operand) {
|
|
1033
|
-
if x.mode == invalid || x.mode == novalue {
|
|
1034
|
-
return
|
|
1035
|
-
}
|
|
1036
|
-
if !check.finiteSize(x.typ) {
|
|
1037
|
-
x.mode = invalid
|
|
1038
|
-
x.typ = Typ[Invalid]
|
|
1020
|
+
x.invalidate()
|
|
1021
|
+
x.typ_ = Typ[Invalid]
|
|
1039
1022
|
}
|
|
1040
1023
|
}
|
|
1041
1024
|
|
|
@@ -1045,8 +1028,8 @@ func (check *Checker) pendingType(x *operand) {
|
|
|
1045
1028
|
func (check *Checker) exprInternal(T *target, x *operand, e ast.Expr, hint Type) exprKind {
|
|
1046
1029
|
// make sure x has a valid state in case of bailout
|
|
1047
1030
|
// (was go.dev/issue/5770)
|
|
1048
|
-
x.
|
|
1049
|
-
x.
|
|
1031
|
+
x.invalidate()
|
|
1032
|
+
x.typ_ = Typ[Invalid]
|
|
1050
1033
|
|
|
1051
1034
|
switch e := e.(type) {
|
|
1052
1035
|
case *ast.BadExpr:
|
|
@@ -1062,19 +1045,19 @@ func (check *Checker) exprInternal(T *target, x *operand, e ast.Expr, hint Type)
|
|
|
1062
1045
|
|
|
1063
1046
|
case *ast.BasicLit:
|
|
1064
1047
|
check.basicLit(x, e)
|
|
1065
|
-
if x.
|
|
1048
|
+
if !x.isValid() {
|
|
1066
1049
|
goto Error
|
|
1067
1050
|
}
|
|
1068
1051
|
|
|
1069
1052
|
case *ast.FuncLit:
|
|
1070
1053
|
check.funcLit(x, e)
|
|
1071
|
-
if x.
|
|
1054
|
+
if !x.isValid() {
|
|
1072
1055
|
goto Error
|
|
1073
1056
|
}
|
|
1074
1057
|
|
|
1075
1058
|
case *ast.CompositeLit:
|
|
1076
1059
|
check.compositeLit(x, e, hint)
|
|
1077
|
-
if x.
|
|
1060
|
+
if !x.isValid() {
|
|
1078
1061
|
goto Error
|
|
1079
1062
|
}
|
|
1080
1063
|
|
|
@@ -1095,19 +1078,19 @@ func (check *Checker) exprInternal(T *target, x *operand, e ast.Expr, hint Type)
|
|
|
1095
1078
|
}
|
|
1096
1079
|
check.funcInst(T, e.Pos(), x, ix, true)
|
|
1097
1080
|
}
|
|
1098
|
-
if x.
|
|
1081
|
+
if !x.isValid() {
|
|
1099
1082
|
goto Error
|
|
1100
1083
|
}
|
|
1101
1084
|
|
|
1102
1085
|
case *ast.SliceExpr:
|
|
1103
1086
|
check.sliceExpr(x, e)
|
|
1104
|
-
if x.
|
|
1087
|
+
if !x.isValid() {
|
|
1105
1088
|
goto Error
|
|
1106
1089
|
}
|
|
1107
1090
|
|
|
1108
1091
|
case *ast.TypeAssertExpr:
|
|
1109
1092
|
check.expr(nil, x, e.X)
|
|
1110
|
-
if x.
|
|
1093
|
+
if !x.isValid() {
|
|
1111
1094
|
goto Error
|
|
1112
1095
|
}
|
|
1113
1096
|
// x.(type) expressions are handled explicitly in type switches
|
|
@@ -1117,11 +1100,11 @@ func (check *Checker) exprInternal(T *target, x *operand, e ast.Expr, hint Type)
|
|
|
1117
1100
|
check.error(e, BadTypeKeyword, "use of .(type) outside type switch")
|
|
1118
1101
|
goto Error
|
|
1119
1102
|
}
|
|
1120
|
-
if isTypeParam(x.typ) {
|
|
1103
|
+
if isTypeParam(x.typ()) {
|
|
1121
1104
|
check.errorf(x, InvalidAssert, invalidOp+"cannot use type assertion on type parameter value %s", x)
|
|
1122
1105
|
goto Error
|
|
1123
1106
|
}
|
|
1124
|
-
if _, ok := x.typ.Underlying().(*Interface); !ok {
|
|
1107
|
+
if _, ok := x.typ().Underlying().(*Interface); !ok {
|
|
1125
1108
|
check.errorf(x, InvalidAssert, invalidOp+"%s is not an interface", x)
|
|
1126
1109
|
goto Error
|
|
1127
1110
|
}
|
|
@@ -1129,24 +1112,28 @@ func (check *Checker) exprInternal(T *target, x *operand, e ast.Expr, hint Type)
|
|
|
1129
1112
|
if !isValid(T) {
|
|
1130
1113
|
goto Error
|
|
1131
1114
|
}
|
|
1115
|
+
// We cannot assert to an incomplete type; make sure it's complete.
|
|
1116
|
+
if !check.isComplete(T) {
|
|
1117
|
+
goto Error
|
|
1118
|
+
}
|
|
1132
1119
|
check.typeAssertion(e, x, T, false)
|
|
1133
|
-
x.
|
|
1134
|
-
x.
|
|
1120
|
+
x.mode_ = commaok
|
|
1121
|
+
x.typ_ = T
|
|
1135
1122
|
|
|
1136
1123
|
case *ast.CallExpr:
|
|
1137
1124
|
return check.callExpr(x, e)
|
|
1138
1125
|
|
|
1139
1126
|
case *ast.StarExpr:
|
|
1140
1127
|
check.exprOrType(x, e.X, false)
|
|
1141
|
-
switch x.mode {
|
|
1128
|
+
switch x.mode() {
|
|
1142
1129
|
case invalid:
|
|
1143
1130
|
goto Error
|
|
1144
1131
|
case typexpr:
|
|
1145
|
-
check.validVarType(e.X, x.typ)
|
|
1146
|
-
x.
|
|
1132
|
+
check.validVarType(e.X, x.typ())
|
|
1133
|
+
x.typ_ = &Pointer{base: x.typ()}
|
|
1147
1134
|
default:
|
|
1148
1135
|
var base Type
|
|
1149
|
-
if !underIs(x.typ, func(u Type) bool {
|
|
1136
|
+
if !underIs(x.typ(), func(u Type) bool {
|
|
1150
1137
|
p, _ := u.(*Pointer)
|
|
1151
1138
|
if p == nil {
|
|
1152
1139
|
check.errorf(x, InvalidIndirection, invalidOp+"cannot indirect %s", x)
|
|
@@ -1161,13 +1148,17 @@ func (check *Checker) exprInternal(T *target, x *operand, e ast.Expr, hint Type)
|
|
|
1161
1148
|
}) {
|
|
1162
1149
|
goto Error
|
|
1163
1150
|
}
|
|
1164
|
-
|
|
1165
|
-
|
|
1151
|
+
// We cannot dereference a pointer with an incomplete base type; make sure it's complete.
|
|
1152
|
+
if !check.isComplete(base) {
|
|
1153
|
+
goto Error
|
|
1154
|
+
}
|
|
1155
|
+
x.mode_ = variable
|
|
1156
|
+
x.typ_ = base
|
|
1166
1157
|
}
|
|
1167
1158
|
|
|
1168
1159
|
case *ast.UnaryExpr:
|
|
1169
1160
|
check.unary(x, e)
|
|
1170
|
-
if x.
|
|
1161
|
+
if !x.isValid() {
|
|
1171
1162
|
goto Error
|
|
1172
1163
|
}
|
|
1173
1164
|
if e.Op == token.ARROW {
|
|
@@ -1177,7 +1168,7 @@ func (check *Checker) exprInternal(T *target, x *operand, e ast.Expr, hint Type)
|
|
|
1177
1168
|
|
|
1178
1169
|
case *ast.BinaryExpr:
|
|
1179
1170
|
check.binary(x, e, e.X, e.Y, e.Op, e.OpPos)
|
|
1180
|
-
if x.
|
|
1171
|
+
if !x.isValid() {
|
|
1181
1172
|
goto Error
|
|
1182
1173
|
}
|
|
1183
1174
|
|
|
@@ -1188,8 +1179,8 @@ func (check *Checker) exprInternal(T *target, x *operand, e ast.Expr, hint Type)
|
|
|
1188
1179
|
|
|
1189
1180
|
case *ast.ArrayType, *ast.StructType, *ast.FuncType,
|
|
1190
1181
|
*ast.InterfaceType, *ast.MapType, *ast.ChanType:
|
|
1191
|
-
x.
|
|
1192
|
-
x.
|
|
1182
|
+
x.mode_ = typexpr
|
|
1183
|
+
x.typ_ = check.typ(e)
|
|
1193
1184
|
// Note: rawExpr (caller of exprInternal) will call check.recordTypeAndValue
|
|
1194
1185
|
// even though check.typ has already called it. This is fine as both
|
|
1195
1186
|
// times the same expression and type are recorded. It is also not a
|
|
@@ -1205,7 +1196,7 @@ func (check *Checker) exprInternal(T *target, x *operand, e ast.Expr, hint Type)
|
|
|
1205
1196
|
return expression
|
|
1206
1197
|
|
|
1207
1198
|
Error:
|
|
1208
|
-
x.
|
|
1199
|
+
x.invalidate()
|
|
1209
1200
|
x.expr = e
|
|
1210
1201
|
return statement // avoid follow-up errors
|
|
1211
1202
|
}
|
|
@@ -1255,7 +1246,7 @@ func keyVal(x constant.Value) any {
|
|
|
1255
1246
|
// typeAssertion checks x.(T). The type of x must be an interface.
|
|
1256
1247
|
func (check *Checker) typeAssertion(e ast.Expr, x *operand, T Type, typeSwitch bool) {
|
|
1257
1248
|
var cause string
|
|
1258
|
-
if check.assertableTo(x.typ, T, &cause) {
|
|
1249
|
+
if check.assertableTo(x.typ(), T, &cause) {
|
|
1259
1250
|
return // success
|
|
1260
1251
|
}
|
|
1261
1252
|
|
|
@@ -1264,7 +1255,7 @@ func (check *Checker) typeAssertion(e ast.Expr, x *operand, T Type, typeSwitch b
|
|
|
1264
1255
|
return
|
|
1265
1256
|
}
|
|
1266
1257
|
|
|
1267
|
-
check.errorf(e, ImpossibleAssert, "impossible type assertion: %s\n\t%s does not implement %s %s", e, T, x.typ, cause)
|
|
1258
|
+
check.errorf(e, ImpossibleAssert, "impossible type assertion: %s\n\t%s does not implement %s %s", e, T, x.typ(), cause)
|
|
1268
1259
|
}
|
|
1269
1260
|
|
|
1270
1261
|
// expr typechecks expression e and initializes x with the expression value.
|
|
@@ -1279,8 +1270,8 @@ func (check *Checker) expr(T *target, x *operand, e ast.Expr) {
|
|
|
1279
1270
|
}
|
|
1280
1271
|
|
|
1281
1272
|
// genericExpr is like expr but the result may also be generic.
|
|
1282
|
-
func (check *Checker) genericExpr(x *operand, e ast.Expr) {
|
|
1283
|
-
check.rawExpr(nil, x, e,
|
|
1273
|
+
func (check *Checker) genericExpr(x *operand, e ast.Expr, hint Type) {
|
|
1274
|
+
check.rawExpr(nil, x, e, hint, true)
|
|
1284
1275
|
check.exclude(x, 1<<novalue|1<<builtin|1<<typexpr)
|
|
1285
1276
|
check.singleValue(x)
|
|
1286
1277
|
}
|
|
@@ -1295,22 +1286,31 @@ func (check *Checker) multiExpr(e ast.Expr, allowCommaOk bool) (list []*operand,
|
|
|
1295
1286
|
check.rawExpr(nil, &x, e, nil, false)
|
|
1296
1287
|
check.exclude(&x, 1<<novalue|1<<builtin|1<<typexpr)
|
|
1297
1288
|
|
|
1298
|
-
if t, ok := x.typ.(*Tuple); ok && x.
|
|
1289
|
+
if t, ok := x.typ().(*Tuple); ok && x.isValid() {
|
|
1299
1290
|
// multiple values
|
|
1300
1291
|
list = make([]*operand, t.Len())
|
|
1301
1292
|
for i, v := range t.vars {
|
|
1302
|
-
|
|
1293
|
+
// create a dummy expression (in place of e) for better error messages
|
|
1294
|
+
dummy := ast.NewIdent(nth(i+1, "function result"))
|
|
1295
|
+
dummy.NamePos = e.Pos() // fix position
|
|
1296
|
+
list[i] = &operand{mode_: value, expr: dummy, typ_: v.typ}
|
|
1303
1297
|
}
|
|
1304
1298
|
return
|
|
1305
1299
|
}
|
|
1306
1300
|
|
|
1307
1301
|
// exactly one (possibly invalid or comma-ok) value
|
|
1308
1302
|
list = []*operand{&x}
|
|
1309
|
-
if allowCommaOk && (x.mode == mapindex || x.mode == commaok || x.mode == commaerr) {
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1303
|
+
if allowCommaOk && (x.mode() == mapindex || x.mode() == commaok || x.mode() == commaerr) {
|
|
1304
|
+
var what string = "ok value of (comma, ok) expression"
|
|
1305
|
+
var typ Type = Typ[UntypedBool]
|
|
1306
|
+
if x.mode() == commaerr {
|
|
1307
|
+
what = "err value of (comma, err) expression"
|
|
1308
|
+
typ = universeError
|
|
1309
|
+
}
|
|
1310
|
+
// create a dummy expression (in place of e) for better error messages
|
|
1311
|
+
dummy := ast.NewIdent(what)
|
|
1312
|
+
dummy.NamePos = e.Pos() // fix position
|
|
1313
|
+
x2 := &operand{mode_: value, expr: dummy, typ_: typ}
|
|
1314
1314
|
list = append(list, x2)
|
|
1315
1315
|
commaOk = true
|
|
1316
1316
|
}
|
|
@@ -1318,16 +1318,24 @@ func (check *Checker) multiExpr(e ast.Expr, allowCommaOk bool) (list []*operand,
|
|
|
1318
1318
|
return
|
|
1319
1319
|
}
|
|
1320
1320
|
|
|
1321
|
-
//
|
|
1322
|
-
//
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1321
|
+
// nth returns a string of the form "nth " + what, where nth
|
|
1322
|
+
// stands for 1st, 2nd, 3rd, 4th, etc. depending on n.
|
|
1323
|
+
func nth(n int, what string) string {
|
|
1324
|
+
var ext string
|
|
1325
|
+
switch n {
|
|
1326
|
+
case 1:
|
|
1327
|
+
ext = "st"
|
|
1328
|
+
case 2:
|
|
1329
|
+
ext = "nd"
|
|
1330
|
+
case 3:
|
|
1331
|
+
ext = "rd"
|
|
1332
|
+
default:
|
|
1333
|
+
ext = "th"
|
|
1334
|
+
}
|
|
1335
|
+
return fmt.Sprintf("%d%s %s", n, ext, what)
|
|
1329
1336
|
}
|
|
1330
1337
|
|
|
1338
|
+
// exprOrType typechecks expression or type e and initializes x with the expression value or type.
|
|
1331
1339
|
// exprOrType typechecks expression or type e and initializes x with the expression value or type.
|
|
1332
1340
|
// If allowGeneric is set, the operand type may be an uninstantiated parameterized type or function
|
|
1333
1341
|
// value.
|
|
@@ -1341,10 +1349,10 @@ func (check *Checker) exprOrType(x *operand, e ast.Expr, allowGeneric bool) {
|
|
|
1341
1349
|
// exclude reports an error if x.mode is in modeset and sets x.mode to invalid.
|
|
1342
1350
|
// The modeset may contain any of 1<<novalue, 1<<builtin, 1<<typexpr.
|
|
1343
1351
|
func (check *Checker) exclude(x *operand, modeset uint) {
|
|
1344
|
-
if modeset&(1<<x.mode) != 0 {
|
|
1352
|
+
if modeset&(1<<x.mode()) != 0 {
|
|
1345
1353
|
var msg string
|
|
1346
1354
|
var code Code
|
|
1347
|
-
switch x.mode {
|
|
1355
|
+
switch x.mode() {
|
|
1348
1356
|
case novalue:
|
|
1349
1357
|
if modeset&(1<<typexpr) != 0 {
|
|
1350
1358
|
msg = "%s used as value"
|
|
@@ -1362,18 +1370,18 @@ func (check *Checker) exclude(x *operand, modeset uint) {
|
|
|
1362
1370
|
panic("unreachable")
|
|
1363
1371
|
}
|
|
1364
1372
|
check.errorf(x, code, msg, x)
|
|
1365
|
-
x.
|
|
1373
|
+
x.invalidate()
|
|
1366
1374
|
}
|
|
1367
1375
|
}
|
|
1368
1376
|
|
|
1369
1377
|
// singleValue reports an error if x describes a tuple and sets x.mode to invalid.
|
|
1370
1378
|
func (check *Checker) singleValue(x *operand) {
|
|
1371
|
-
if x.mode == value {
|
|
1379
|
+
if x.mode() == value {
|
|
1372
1380
|
// tuple types are never named - no need for underlying type below
|
|
1373
|
-
if t, ok := x.typ.(*Tuple); ok {
|
|
1381
|
+
if t, ok := x.typ().(*Tuple); ok {
|
|
1374
1382
|
assert(t.Len() != 1)
|
|
1375
1383
|
check.errorf(x, TooManyValues, "multiple-value %s in single-value context", x)
|
|
1376
|
-
x.
|
|
1384
|
+
x.invalidate()
|
|
1377
1385
|
}
|
|
1378
1386
|
}
|
|
1379
1387
|
}
|