├── .github └── workflows │ ├── all.yml │ └── lint.yml ├── .gitignore ├── .golangci.yml ├── LICENSE ├── README.md ├── build.sh ├── chanutil └── io.go ├── contextplus ├── c.go ├── cause_test.go ├── contextplus.go └── unit_test.go ├── evergreen.yml ├── evergreen ├── generate_expansions.sh ├── go_lint.py ├── go_test.py ├── prelude.sh ├── prelude_db_contrib_tool.sh ├── prelude_python.sh ├── prelude_venv.sh ├── prelude_workdir.sh └── run_python_script.sh ├── go.mod ├── go.sum ├── gorules ├── interface_any.go └── zerolog_interface_any.go ├── internal ├── keystring │ ├── keystring_decoder.go │ └── keystring_test.go ├── logger │ └── logger.go ├── partitions │ ├── bson.go │ ├── bson_test.go │ ├── partition.go │ ├── partition_test.go │ ├── partitions.go │ └── unit_test.go ├── reportutils │ ├── reportutils.go │ └── reportutils_test.go ├── retry │ ├── constants.go │ ├── error.go │ ├── retry.go │ ├── retry_info.go │ ├── retryer.go │ ├── retryer_test.go │ └── unit_test.go ├── testutil │ └── testutil.go ├── types │ ├── types.go │ └── types_test.go ├── util │ ├── agg.go │ ├── askserver.go │ ├── bson.go │ ├── bson_test.go │ ├── cluster_time.go │ ├── clusterinfo.go │ ├── collections.go │ ├── context.go │ ├── error.go │ ├── error_test.go │ ├── eventual.go │ ├── eventual_test.go │ ├── invariant.go │ ├── math.go │ ├── sharding.go │ ├── uuid.go │ └── uuid_test.go ├── uuidutil │ └── get_uuid.go └── verifier │ ├── bson_compare.go │ ├── bson_compare_test.go │ ├── change_stream.go │ ├── change_stream_test.go │ ├── check.go │ ├── check_runner.go │ ├── check_test.go │ ├── clustertime.go │ ├── clustertime_test.go │ ├── compare.go │ ├── compare_test.go │ ├── event_recorder.go │ ├── generation.go │ ├── integration_test_suite.go │ ├── list_namespaces.go │ ├── logging_setup.go │ ├── metadata.go │ ├── migration_verifier.go │ ├── migration_verifier_bench_test.go │ ├── migration_verifier_test.go │ ├── mismatches.go │ ├── mongos_refresh.go │ ├── nsmap.go │ ├── nsmap_test.go │ ├── pprof.go │ ├── recheck.go │ ├── recheck_test.go │ ├── reset.go │ ├── reset_test.go │ ├── result.go │ ├── sharding.go │ ├── sharding_test.go │ ├── statistics.go │ ├── summary.go │ ├── uri.go │ ├── util.go │ ├── verification_task.go │ ├── web_server_test.go │ ├── webserver.go │ ├── webserver │ └── binding_extjson.go │ └── worker_tracker.go ├── main └── migration_verifier.go ├── mbson ├── bson_raw.go └── unit_test.go ├── mmongo ├── agg.go └── error.go ├── mslices ├── slices.go └── slices_test.go ├── mstrings └── builder.go ├── msync ├── dataguard.go ├── dataguard_test.go ├── typed_atomic.go └── typed_atomic_test.go ├── option ├── bson.go ├── json.go ├── option.go ├── unit_test.go └── validate.go ├── precious.toml ├── test └── benchmark.py └── vendor ├── github.com ├── BurntSushi │ └── toml │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── COMPATIBLE │ │ ├── COPYING │ │ ├── Makefile │ │ ├── README.md │ │ ├── decode.go │ │ ├── decode_meta.go │ │ ├── doc.go │ │ ├── encode.go │ │ ├── encoding_types.go │ │ ├── encoding_types_1.1.go │ │ ├── lex.go │ │ ├── parse.go │ │ ├── session.vim │ │ ├── type_check.go │ │ └── type_fields.go ├── cespare │ └── permute │ │ └── v2 │ │ ├── LICENSE.txt │ │ ├── README.md │ │ └── permute.go ├── cpuguy83 │ └── go-md2man │ │ └── v2 │ │ ├── LICENSE.md │ │ └── md2man │ │ ├── md2man.go │ │ └── roff.go ├── davecgh │ └── go-spew │ │ ├── LICENSE │ │ └── spew │ │ ├── bypass.go │ │ ├── bypasssafe.go │ │ ├── common.go │ │ ├── config.go │ │ ├── doc.go │ │ ├── dump.go │ │ ├── format.go │ │ └── spew.go ├── deckarep │ └── golang-set │ │ └── v2 │ │ ├── .gitignore │ │ ├── LICENSE │ │ ├── README.md │ │ ├── iterator.go │ │ ├── new_improved.jpeg │ │ ├── set.go │ │ ├── threadsafe.go │ │ └── threadunsafe.go ├── dustin │ └── go-humanize │ │ ├── .travis.yml │ │ ├── LICENSE │ │ ├── README.markdown │ │ ├── big.go │ │ ├── bigbytes.go │ │ ├── bytes.go │ │ ├── comma.go │ │ ├── commaf.go │ │ ├── ftoa.go │ │ ├── humanize.go │ │ ├── number.go │ │ ├── ordinals.go │ │ ├── si.go │ │ └── times.go ├── gin-contrib │ └── sse │ │ ├── .travis.yml │ │ ├── LICENSE │ │ ├── README.md │ │ ├── sse-decoder.go │ │ ├── sse-encoder.go │ │ └── writer.go ├── gin-gonic │ └── gin │ │ ├── .gitignore │ │ ├── .golangci.yml │ │ ├── .goreleaser.yaml │ │ ├── AUTHORS.md │ │ ├── BENCHMARKS.md │ │ ├── CHANGELOG.md │ │ ├── CODE_OF_CONDUCT.md │ │ ├── CONTRIBUTING.md │ │ ├── LICENSE │ │ ├── Makefile │ │ ├── README.md │ │ ├── any.go │ │ ├── auth.go │ │ ├── binding │ │ ├── any.go │ │ ├── binding.go │ │ ├── binding_nomsgpack.go │ │ ├── default_validator.go │ │ ├── form.go │ │ ├── form_mapping.go │ │ ├── header.go │ │ ├── json.go │ │ ├── msgpack.go │ │ ├── multipart_form_mapping.go │ │ ├── protobuf.go │ │ ├── query.go │ │ ├── toml.go │ │ ├── uri.go │ │ ├── xml.go │ │ └── yaml.go │ │ ├── codecov.yml │ │ ├── context.go │ │ ├── context_appengine.go │ │ ├── debug.go │ │ ├── deprecated.go │ │ ├── doc.go │ │ ├── errors.go │ │ ├── fs.go │ │ ├── gin.go │ │ ├── internal │ │ ├── bytesconv │ │ │ └── bytesconv.go │ │ └── json │ │ │ ├── go_json.go │ │ │ ├── json.go │ │ │ └── jsoniter.go │ │ ├── logger.go │ │ ├── mode.go │ │ ├── path.go │ │ ├── recovery.go │ │ ├── render │ │ ├── any.go │ │ ├── data.go │ │ ├── html.go │ │ ├── json.go │ │ ├── msgpack.go │ │ ├── protobuf.go │ │ ├── reader.go │ │ ├── redirect.go │ │ ├── render.go │ │ ├── text.go │ │ ├── toml.go │ │ ├── xml.go │ │ └── yaml.go │ │ ├── response_writer.go │ │ ├── routergroup.go │ │ ├── test_helpers.go │ │ ├── tree.go │ │ ├── utils.go │ │ └── version.go ├── go-playground │ ├── locales │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── LICENSE │ │ ├── README.md │ │ ├── currency │ │ │ └── currency.go │ │ ├── logo.png │ │ └── rules.go │ ├── universal-translator │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── LICENSE │ │ ├── Makefile │ │ ├── README.md │ │ ├── errors.go │ │ ├── import_export.go │ │ ├── logo.png │ │ ├── translator.go │ │ └── universal_translator.go │ └── validator │ │ └── v10 │ │ ├── .gitignore │ │ ├── LICENSE │ │ ├── MAINTAINERS.md │ │ ├── Makefile │ │ ├── README.md │ │ ├── baked_in.go │ │ ├── cache.go │ │ ├── country_codes.go │ │ ├── currency_codes.go │ │ ├── doc.go │ │ ├── errors.go │ │ ├── field_level.go │ │ ├── logo.png │ │ ├── postcode_regexes.go │ │ ├── regexes.go │ │ ├── struct_level.go │ │ ├── translations.go │ │ ├── util.go │ │ ├── validator.go │ │ └── validator_instance.go ├── goccy │ └── go-json │ │ ├── .codecov.yml │ │ ├── .gitignore │ │ ├── .golangci.yml │ │ ├── CHANGELOG.md │ │ ├── LICENSE │ │ ├── Makefile │ │ ├── README.md │ │ ├── color.go │ │ ├── decode.go │ │ ├── docker-compose.yml │ │ ├── encode.go │ │ ├── error.go │ │ ├── internal │ │ ├── decoder │ │ │ ├── anonymous_field.go │ │ │ ├── array.go │ │ │ ├── bool.go │ │ │ ├── bytes.go │ │ │ ├── compile.go │ │ │ ├── compile_norace.go │ │ │ ├── compile_race.go │ │ │ ├── context.go │ │ │ ├── float.go │ │ │ ├── func.go │ │ │ ├── int.go │ │ │ ├── interface.go │ │ │ ├── invalid.go │ │ │ ├── map.go │ │ │ ├── number.go │ │ │ ├── option.go │ │ │ ├── ptr.go │ │ │ ├── slice.go │ │ │ ├── stream.go │ │ │ ├── string.go │ │ │ ├── struct.go │ │ │ ├── type.go │ │ │ ├── uint.go │ │ │ ├── unmarshal_json.go │ │ │ ├── unmarshal_text.go │ │ │ └── wrapped_string.go │ │ ├── encoder │ │ │ ├── code.go │ │ │ ├── compact.go │ │ │ ├── compiler.go │ │ │ ├── compiler_norace.go │ │ │ ├── compiler_race.go │ │ │ ├── context.go │ │ │ ├── decode_rune.go │ │ │ ├── encoder.go │ │ │ ├── indent.go │ │ │ ├── int.go │ │ │ ├── map112.go │ │ │ ├── map113.go │ │ │ ├── opcode.go │ │ │ ├── option.go │ │ │ ├── optype.go │ │ │ ├── query.go │ │ │ ├── string.go │ │ │ ├── string_table.go │ │ │ ├── vm │ │ │ │ ├── debug_vm.go │ │ │ │ ├── hack.go │ │ │ │ ├── util.go │ │ │ │ └── vm.go │ │ │ ├── vm_color │ │ │ │ ├── debug_vm.go │ │ │ │ ├── hack.go │ │ │ │ ├── util.go │ │ │ │ └── vm.go │ │ │ ├── vm_color_indent │ │ │ │ ├── debug_vm.go │ │ │ │ ├── util.go │ │ │ │ └── vm.go │ │ │ └── vm_indent │ │ │ │ ├── debug_vm.go │ │ │ │ ├── hack.go │ │ │ │ ├── util.go │ │ │ │ └── vm.go │ │ ├── errors │ │ │ └── error.go │ │ └── runtime │ │ │ ├── rtype.go │ │ │ ├── struct_field.go │ │ │ └── type.go │ │ ├── json.go │ │ ├── option.go │ │ └── query.go ├── golang │ └── snappy │ │ ├── .gitignore │ │ ├── AUTHORS │ │ ├── CONTRIBUTORS │ │ ├── LICENSE │ │ ├── README │ │ ├── decode.go │ │ ├── decode_amd64.s │ │ ├── decode_arm64.s │ │ ├── decode_asm.go │ │ ├── decode_other.go │ │ ├── encode.go │ │ ├── encode_amd64.s │ │ ├── encode_arm64.s │ │ ├── encode_asm.go │ │ ├── encode_other.go │ │ └── snappy.go ├── google │ └── uuid │ │ ├── .travis.yml │ │ ├── CONTRIBUTING.md │ │ ├── CONTRIBUTORS │ │ ├── LICENSE │ │ ├── README.md │ │ ├── dce.go │ │ ├── doc.go │ │ ├── hash.go │ │ ├── marshal.go │ │ ├── node.go │ │ ├── node_js.go │ │ ├── node_net.go │ │ ├── null.go │ │ ├── sql.go │ │ ├── time.go │ │ ├── util.go │ │ ├── uuid.go │ │ ├── version1.go │ │ └── version4.go ├── huandu │ └── go-clone │ │ ├── .gitignore │ │ ├── LICENSE │ │ ├── README.md │ │ ├── allocator.go │ │ ├── allocatormethods.go │ │ ├── arena.go │ │ ├── arena_go120.go │ │ ├── atomic_go119.go │ │ ├── clone.go │ │ ├── cloner.go │ │ ├── generic │ │ ├── LICENSE │ │ ├── README.md │ │ ├── api.go │ │ ├── arena.go │ │ └── register.go │ │ ├── headers.go │ │ ├── interfacedata.go │ │ ├── mapiter.go │ │ ├── mapiter_go112.go │ │ ├── memory.go │ │ ├── structtype.go │ │ └── wrapper.go ├── json-iterator │ └── go │ │ ├── .codecov.yml │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── Gopkg.lock │ │ ├── Gopkg.toml │ │ ├── LICENSE │ │ ├── README.md │ │ ├── adapter.go │ │ ├── any.go │ │ ├── any_array.go │ │ ├── any_bool.go │ │ ├── any_float.go │ │ ├── any_int32.go │ │ ├── any_int64.go │ │ ├── any_invalid.go │ │ ├── any_nil.go │ │ ├── any_number.go │ │ ├── any_object.go │ │ ├── any_str.go │ │ ├── any_uint32.go │ │ ├── any_uint64.go │ │ ├── build.sh │ │ ├── config.go │ │ ├── fuzzy_mode_convert_table.md │ │ ├── iter.go │ │ ├── iter_array.go │ │ ├── iter_float.go │ │ ├── iter_int.go │ │ ├── iter_object.go │ │ ├── iter_skip.go │ │ ├── iter_skip_sloppy.go │ │ ├── iter_skip_strict.go │ │ ├── iter_str.go │ │ ├── jsoniter.go │ │ ├── pool.go │ │ ├── reflect.go │ │ ├── reflect_array.go │ │ ├── reflect_dynamic.go │ │ ├── reflect_extension.go │ │ ├── reflect_json_number.go │ │ ├── reflect_json_raw_message.go │ │ ├── reflect_map.go │ │ ├── reflect_marshaler.go │ │ ├── reflect_native.go │ │ ├── reflect_optional.go │ │ ├── reflect_slice.go │ │ ├── reflect_struct_decoder.go │ │ ├── reflect_struct_encoder.go │ │ ├── stream.go │ │ ├── stream_float.go │ │ ├── stream_int.go │ │ ├── stream_str.go │ │ └── test.sh ├── klauspost │ └── compress │ │ ├── .gitattributes │ │ ├── .gitignore │ │ ├── .goreleaser.yml │ │ ├── LICENSE │ │ ├── README.md │ │ ├── compressible.go │ │ ├── fse │ │ ├── README.md │ │ ├── bitreader.go │ │ ├── bitwriter.go │ │ ├── bytereader.go │ │ ├── compress.go │ │ ├── decompress.go │ │ └── fse.go │ │ ├── gen.sh │ │ ├── huff0 │ │ ├── .gitignore │ │ ├── README.md │ │ ├── bitreader.go │ │ ├── bitwriter.go │ │ ├── bytereader.go │ │ ├── compress.go │ │ ├── decompress.go │ │ └── huff0.go │ │ ├── internal │ │ └── snapref │ │ │ ├── LICENSE │ │ │ ├── decode.go │ │ │ ├── decode_other.go │ │ │ ├── encode.go │ │ │ ├── encode_other.go │ │ │ └── snappy.go │ │ ├── s2sx.mod │ │ ├── s2sx.sum │ │ └── zstd │ │ ├── README.md │ │ ├── bitreader.go │ │ ├── bitwriter.go │ │ ├── blockdec.go │ │ ├── blockenc.go │ │ ├── blocktype_string.go │ │ ├── bytebuf.go │ │ ├── bytereader.go │ │ ├── decodeheader.go │ │ ├── decoder.go │ │ ├── decoder_options.go │ │ ├── dict.go │ │ ├── enc_base.go │ │ ├── enc_best.go │ │ ├── enc_better.go │ │ ├── enc_dfast.go │ │ ├── enc_fast.go │ │ ├── encoder.go │ │ ├── encoder_options.go │ │ ├── framedec.go │ │ ├── frameenc.go │ │ ├── fse_decoder.go │ │ ├── fse_encoder.go │ │ ├── fse_predefined.go │ │ ├── hash.go │ │ ├── history.go │ │ ├── internal │ │ └── xxhash │ │ │ ├── LICENSE.txt │ │ │ ├── README.md │ │ │ ├── xxhash.go │ │ │ ├── xxhash_amd64.go │ │ │ ├── xxhash_amd64.s │ │ │ ├── xxhash_other.go │ │ │ └── xxhash_safe.go │ │ ├── seqdec.go │ │ ├── seqenc.go │ │ ├── snappy.go │ │ ├── zip.go │ │ └── zstd.go ├── leodido │ └── go-urn │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── LICENSE │ │ ├── README.md │ │ ├── machine.go │ │ ├── machine.go.rl │ │ ├── makefile │ │ └── urn.go ├── mattn │ ├── go-colorable │ │ ├── LICENSE │ │ ├── README.md │ │ ├── colorable_appengine.go │ │ ├── colorable_others.go │ │ ├── colorable_windows.go │ │ ├── go.test.sh │ │ └── noncolorable.go │ ├── go-isatty │ │ ├── LICENSE │ │ ├── README.md │ │ ├── doc.go │ │ ├── go.test.sh │ │ ├── isatty_bsd.go │ │ ├── isatty_others.go │ │ ├── isatty_plan9.go │ │ ├── isatty_solaris.go │ │ ├── isatty_tcgets.go │ │ └── isatty_windows.go │ └── go-runewidth │ │ ├── .travis.yml │ │ ├── LICENSE │ │ ├── README.md │ │ ├── go.test.sh │ │ ├── runewidth.go │ │ ├── runewidth_appengine.go │ │ ├── runewidth_js.go │ │ ├── runewidth_posix.go │ │ ├── runewidth_table.go │ │ └── runewidth_windows.go ├── modern-go │ ├── concurrent │ │ ├── LICENSE │ │ ├── README.md │ │ ├── executor.go │ │ ├── go_above_19.go │ │ ├── go_below_19.go │ │ └── unbounded_executor.go │ └── reflect2 │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── Gopkg.lock │ │ ├── Gopkg.toml │ │ ├── LICENSE │ │ ├── README.md │ │ ├── go_above_118.go │ │ ├── go_above_19.go │ │ ├── go_below_118.go │ │ ├── reflect2.go │ │ ├── reflect2_amd64.s │ │ ├── reflect2_kind.go │ │ ├── relfect2_386.s │ │ ├── relfect2_amd64p32.s │ │ ├── relfect2_arm.s │ │ ├── relfect2_arm64.s │ │ ├── relfect2_mips64x.s │ │ ├── relfect2_mipsx.s │ │ ├── relfect2_ppc64x.s │ │ ├── relfect2_s390x.s │ │ ├── safe_field.go │ │ ├── safe_map.go │ │ ├── safe_slice.go │ │ ├── safe_struct.go │ │ ├── safe_type.go │ │ ├── type_map.go │ │ ├── unsafe_array.go │ │ ├── unsafe_eface.go │ │ ├── unsafe_field.go │ │ ├── unsafe_iface.go │ │ ├── unsafe_link.go │ │ ├── unsafe_map.go │ │ ├── unsafe_ptr.go │ │ ├── unsafe_slice.go │ │ ├── unsafe_struct.go │ │ └── unsafe_type.go ├── montanaflynn │ └── stats │ │ ├── .gitignore │ │ ├── CHANGELOG.md │ │ ├── DOCUMENTATION.md │ │ ├── LICENSE │ │ ├── Makefile │ │ ├── README.md │ │ ├── correlation.go │ │ ├── cumulative_sum.go │ │ ├── data.go │ │ ├── describe.go │ │ ├── deviation.go │ │ ├── distances.go │ │ ├── doc.go │ │ ├── entropy.go │ │ ├── errors.go │ │ ├── geometric_distribution.go │ │ ├── legacy.go │ │ ├── load.go │ │ ├── max.go │ │ ├── mean.go │ │ ├── median.go │ │ ├── min.go │ │ ├── mode.go │ │ ├── norm.go │ │ ├── outlier.go │ │ ├── percentile.go │ │ ├── quartile.go │ │ ├── ranksum.go │ │ ├── regression.go │ │ ├── round.go │ │ ├── sample.go │ │ ├── sigmoid.go │ │ ├── softmax.go │ │ ├── sum.go │ │ ├── util.go │ │ └── variance.go ├── olekukonko │ └── tablewriter │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── LICENSE.md │ │ ├── README.md │ │ ├── csv.go │ │ ├── table.go │ │ ├── table_with_color.go │ │ ├── util.go │ │ └── wrap.go ├── pelletier │ └── go-toml │ │ └── v2 │ │ ├── .dockerignore │ │ ├── .gitattributes │ │ ├── .gitignore │ │ ├── .golangci.toml │ │ ├── .goreleaser.yaml │ │ ├── CONTRIBUTING.md │ │ ├── Dockerfile │ │ ├── LICENSE │ │ ├── README.md │ │ ├── SECURITY.md │ │ ├── ci.sh │ │ ├── decode.go │ │ ├── doc.go │ │ ├── errors.go │ │ ├── internal │ │ ├── ast │ │ │ ├── ast.go │ │ │ ├── builder.go │ │ │ └── kind.go │ │ ├── danger │ │ │ ├── danger.go │ │ │ └── typeid.go │ │ └── tracker │ │ │ ├── key.go │ │ │ ├── seen.go │ │ │ └── tracker.go │ │ ├── localtime.go │ │ ├── marshaler.go │ │ ├── parser.go │ │ ├── scanner.go │ │ ├── strict.go │ │ ├── toml.abnf │ │ ├── types.go │ │ ├── unmarshaler.go │ │ └── utf8.go ├── pkg │ └── errors │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── LICENSE │ │ ├── Makefile │ │ ├── README.md │ │ ├── appveyor.yml │ │ ├── errors.go │ │ ├── go113.go │ │ └── stack.go ├── pmezard │ └── go-difflib │ │ ├── LICENSE │ │ └── difflib │ │ └── difflib.go ├── quasilyte │ └── go-ruleguard │ │ └── dsl │ │ ├── LICENSE │ │ ├── bundle.go │ │ ├── do.go │ │ ├── dsl.go │ │ ├── filter.go │ │ ├── internal.go │ │ └── types │ │ ├── ext.go │ │ ├── type_impl.go │ │ └── types.go ├── rs │ └── zerolog │ │ ├── .gitignore │ │ ├── CONTRIBUTING.md │ │ ├── LICENSE │ │ ├── README.md │ │ ├── array.go │ │ ├── console.go │ │ ├── context.go │ │ ├── ctx.go │ │ ├── encoder.go │ │ ├── encoder_cbor.go │ │ ├── encoder_json.go │ │ ├── event.go │ │ ├── example.jsonl │ │ ├── fields.go │ │ ├── globals.go │ │ ├── go112.go │ │ ├── hook.go │ │ ├── internal │ │ ├── cbor │ │ │ ├── README.md │ │ │ ├── base.go │ │ │ ├── cbor.go │ │ │ ├── decode_stream.go │ │ │ ├── string.go │ │ │ ├── time.go │ │ │ └── types.go │ │ └── json │ │ │ ├── base.go │ │ │ ├── bytes.go │ │ │ ├── string.go │ │ │ ├── time.go │ │ │ └── types.go │ │ ├── log.go │ │ ├── log │ │ └── log.go │ │ ├── not_go112.go │ │ ├── pkgerrors │ │ └── stacktrace.go │ │ ├── pretty.png │ │ ├── sampler.go │ │ ├── syslog.go │ │ └── writer.go ├── russross │ └── blackfriday │ │ └── v2 │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── LICENSE.txt │ │ ├── README.md │ │ ├── block.go │ │ ├── doc.go │ │ ├── entities.go │ │ ├── esc.go │ │ ├── html.go │ │ ├── inline.go │ │ ├── markdown.go │ │ ├── node.go │ │ └── smartypants.go ├── samber │ ├── lo │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── CHANGELOG.md │ │ ├── Dockerfile │ │ ├── LICENSE │ │ ├── Makefile │ │ ├── README.md │ │ ├── channel.go │ │ ├── concurrency.go │ │ ├── condition.go │ │ ├── constraints.go │ │ ├── errors.go │ │ ├── find.go │ │ ├── func.go │ │ ├── internal │ │ │ ├── constraints │ │ │ │ ├── constraints.go │ │ │ │ ├── ordered_go118.go │ │ │ │ └── ordered_go121.go │ │ │ └── rand │ │ │ │ ├── ordered_go118.go │ │ │ │ └── ordered_go122.go │ │ ├── intersect.go │ │ ├── map.go │ │ ├── math.go │ │ ├── retry.go │ │ ├── slice.go │ │ ├── string.go │ │ ├── time.go │ │ ├── tuples.go │ │ ├── type_manipulation.go │ │ └── types.go │ └── mo │ │ ├── .gitignore │ │ ├── Dockerfile │ │ ├── LICENSE │ │ ├── Makefile │ │ ├── README.md │ │ ├── do.go │ │ ├── either.go │ │ ├── either3.go │ │ ├── either4.go │ │ ├── either5.go │ │ ├── fold.go │ │ ├── future.go │ │ ├── io.go │ │ ├── io_either.go │ │ ├── option.go │ │ ├── option_go118.go │ │ ├── option_go122.go │ │ ├── result.go │ │ ├── state.go │ │ ├── task.go │ │ ├── task_either.go │ │ ├── types.go │ │ └── utils.go ├── stretchr │ └── testify │ │ ├── LICENSE │ │ ├── assert │ │ ├── assertion_compare.go │ │ ├── assertion_compare_can_convert.go │ │ ├── assertion_compare_legacy.go │ │ ├── assertion_format.go │ │ ├── assertion_format.go.tmpl │ │ ├── assertion_forward.go │ │ ├── assertion_forward.go.tmpl │ │ ├── assertion_order.go │ │ ├── assertions.go │ │ ├── doc.go │ │ ├── errors.go │ │ ├── forward_assertions.go │ │ └── http_assertions.go │ │ ├── require │ │ ├── doc.go │ │ ├── forward_requirements.go │ │ ├── require.go │ │ ├── require.go.tmpl │ │ ├── require_forward.go │ │ ├── require_forward.go.tmpl │ │ └── requirements.go │ │ └── suite │ │ ├── doc.go │ │ ├── interfaces.go │ │ ├── stats.go │ │ └── suite.go ├── ugorji │ └── go │ │ └── codec │ │ ├── 0_importpath.go │ │ ├── LICENSE │ │ ├── README.md │ │ ├── binc.go │ │ ├── build.sh │ │ ├── cbor.go │ │ ├── codecgen.go │ │ ├── decimal.go │ │ ├── decode.go │ │ ├── doc.go │ │ ├── encode.go │ │ ├── fast-path.generated.go │ │ ├── fast-path.go.tmpl │ │ ├── fast-path.not.go │ │ ├── gen-dec-array.go.tmpl │ │ ├── gen-dec-map.go.tmpl │ │ ├── gen-enc-chan.go.tmpl │ │ ├── gen-helper.generated.go │ │ ├── gen-helper.go.tmpl │ │ ├── gen.generated.go │ │ ├── gen.go │ │ ├── goversion_arrayof_gte_go15.go │ │ ├── goversion_arrayof_lt_go15.go │ │ ├── goversion_fmt_time_gte_go15.go │ │ ├── goversion_fmt_time_lt_go15.go │ │ ├── goversion_makemap_lt_go110.go │ │ ├── goversion_makemap_not_unsafe_gte_go110.go │ │ ├── goversion_makemap_unsafe_gte_go110.go │ │ ├── goversion_maprange_gte_go112.go │ │ ├── goversion_maprange_lt_go112.go │ │ ├── goversion_unexportedembeddedptr_gte_go110.go │ │ ├── goversion_unexportedembeddedptr_lt_go110.go │ │ ├── goversion_unsupported_lt_go14.go │ │ ├── goversion_vendor_eq_go15.go │ │ ├── goversion_vendor_eq_go16.go │ │ ├── goversion_vendor_gte_go17.go │ │ ├── goversion_vendor_lt_go15.go │ │ ├── helper.go │ │ ├── helper.s │ │ ├── helper_internal.go │ │ ├── helper_not_unsafe.go │ │ ├── helper_not_unsafe_not_gc.go │ │ ├── helper_unsafe.go │ │ ├── helper_unsafe_compiler_gc.go │ │ ├── helper_unsafe_compiler_not_gc.go │ │ ├── json.go │ │ ├── mammoth-test.go.tmpl │ │ ├── mammoth2-test.go.tmpl │ │ ├── msgpack.go │ │ ├── reader.go │ │ ├── register_ext.go │ │ ├── rpc.go │ │ ├── simple.go │ │ ├── sort-slice.generated.go │ │ ├── sort-slice.go.tmpl │ │ ├── test-cbor-goldens.json │ │ ├── test.py │ │ └── writer.go ├── urfave │ └── cli │ │ ├── .flake8 │ │ ├── .gitignore │ │ ├── CODE_OF_CONDUCT.md │ │ ├── LICENSE │ │ ├── README.md │ │ ├── altsrc │ │ ├── flag.go │ │ ├── flag_generated.go │ │ ├── input_source_context.go │ │ ├── json_source_context.go │ │ ├── map_input_source.go │ │ ├── toml_file_loader.go │ │ └── yaml_file_loader.go │ │ ├── app.go │ │ ├── appveyor.yml │ │ ├── category.go │ │ ├── cli.go │ │ ├── command.go │ │ ├── context.go │ │ ├── docs.go │ │ ├── errors.go │ │ ├── fish.go │ │ ├── flag.go │ │ ├── flag_bool.go │ │ ├── flag_bool_t.go │ │ ├── flag_duration.go │ │ ├── flag_float64.go │ │ ├── flag_generic.go │ │ ├── flag_int.go │ │ ├── flag_int64.go │ │ ├── flag_int64_slice.go │ │ ├── flag_int_slice.go │ │ ├── flag_string.go │ │ ├── flag_string_slice.go │ │ ├── flag_uint.go │ │ ├── flag_uint64.go │ │ ├── funcs.go │ │ ├── help.go │ │ ├── parse.go │ │ ├── sort.go │ │ └── template.go ├── xdg-go │ ├── pbkdf2 │ │ ├── .gitignore │ │ ├── LICENSE │ │ ├── README.md │ │ └── pbkdf2.go │ ├── scram │ │ ├── .gitignore │ │ ├── CHANGELOG.md │ │ ├── LICENSE │ │ ├── README.md │ │ ├── client.go │ │ ├── client_conv.go │ │ ├── common.go │ │ ├── doc.go │ │ ├── parse.go │ │ ├── scram.go │ │ ├── server.go │ │ └── server_conv.go │ └── stringprep │ │ ├── .gitignore │ │ ├── CHANGELOG.md │ │ ├── LICENSE │ │ ├── README.md │ │ ├── bidi.go │ │ ├── doc.go │ │ ├── error.go │ │ ├── map.go │ │ ├── profile.go │ │ ├── saslprep.go │ │ ├── set.go │ │ └── tables.go └── youmark │ └── pkcs8 │ ├── .gitignore │ ├── LICENSE │ ├── README │ ├── README.md │ ├── cipher.go │ ├── cipher_3des.go │ ├── cipher_aes.go │ ├── kdf_pbkdf2.go │ ├── kdf_scrypt.go │ └── pkcs8.go ├── go.mongodb.org └── mongo-driver │ ├── LICENSE │ ├── bson │ ├── bson.go │ ├── bsoncodec │ │ ├── array_codec.go │ │ ├── bsoncodec.go │ │ ├── byte_slice_codec.go │ │ ├── codec_cache.go │ │ ├── cond_addr_codec.go │ │ ├── default_value_decoders.go │ │ ├── default_value_encoders.go │ │ ├── doc.go │ │ ├── empty_interface_codec.go │ │ ├── map_codec.go │ │ ├── mode.go │ │ ├── pointer_codec.go │ │ ├── proxy.go │ │ ├── registry.go │ │ ├── slice_codec.go │ │ ├── string_codec.go │ │ ├── struct_codec.go │ │ ├── struct_tag_parser.go │ │ ├── time_codec.go │ │ ├── types.go │ │ └── uint_codec.go │ ├── bsonoptions │ │ ├── byte_slice_codec_options.go │ │ ├── doc.go │ │ ├── empty_interface_codec_options.go │ │ ├── map_codec_options.go │ │ ├── slice_codec_options.go │ │ ├── string_codec_options.go │ │ ├── struct_codec_options.go │ │ ├── time_codec_options.go │ │ └── uint_codec_options.go │ ├── bsonrw │ │ ├── copier.go │ │ ├── doc.go │ │ ├── extjson_parser.go │ │ ├── extjson_reader.go │ │ ├── extjson_tables.go │ │ ├── extjson_wrappers.go │ │ ├── extjson_writer.go │ │ ├── json_scanner.go │ │ ├── mode.go │ │ ├── reader.go │ │ ├── value_reader.go │ │ ├── value_writer.go │ │ └── writer.go │ ├── bsontype │ │ └── bsontype.go │ ├── decoder.go │ ├── doc.go │ ├── encoder.go │ ├── marshal.go │ ├── primitive │ │ ├── decimal.go │ │ ├── objectid.go │ │ └── primitive.go │ ├── primitive_codecs.go │ ├── raw.go │ ├── raw_element.go │ ├── raw_value.go │ ├── registry.go │ ├── types.go │ └── unmarshal.go │ ├── event │ ├── doc.go │ └── monitoring.go │ ├── internal │ ├── aws │ │ ├── awserr │ │ │ ├── error.go │ │ │ └── types.go │ │ ├── credentials │ │ │ ├── chain_provider.go │ │ │ └── credentials.go │ │ ├── signer │ │ │ └── v4 │ │ │ │ ├── header_rules.go │ │ │ │ ├── request.go │ │ │ │ ├── uri_path.go │ │ │ │ └── v4.go │ │ └── types.go │ ├── bsonutil │ │ └── bsonutil.go │ ├── codecutil │ │ └── encoding.go │ ├── credproviders │ │ ├── assume_role_provider.go │ │ ├── ec2_provider.go │ │ ├── ecs_provider.go │ │ ├── env_provider.go │ │ ├── imds_provider.go │ │ └── static_provider.go │ ├── csfle │ │ └── csfle.go │ ├── csot │ │ └── csot.go │ ├── driverutil │ │ ├── hello.go │ │ └── operation.go │ ├── handshake │ │ └── handshake.go │ ├── httputil │ │ └── httputil.go │ ├── logger │ │ ├── component.go │ │ ├── context.go │ │ ├── io_sink.go │ │ ├── level.go │ │ └── logger.go │ ├── ptrutil │ │ └── int64.go │ ├── rand │ │ ├── bits.go │ │ ├── exp.go │ │ ├── normal.go │ │ ├── rand.go │ │ └── rng.go │ ├── randutil │ │ └── randutil.go │ └── uuid │ │ └── uuid.go │ ├── mongo │ ├── address │ │ └── addr.go │ ├── background_context.go │ ├── batch_cursor.go │ ├── bulk_write.go │ ├── bulk_write_models.go │ ├── change_stream.go │ ├── change_stream_deployment.go │ ├── client.go │ ├── client_encryption.go │ ├── collection.go │ ├── crypt_retrievers.go │ ├── cursor.go │ ├── database.go │ ├── description │ │ ├── description.go │ │ ├── server.go │ │ ├── server_kind.go │ │ ├── server_selector.go │ │ ├── topology.go │ │ ├── topology_kind.go │ │ ├── topology_version.go │ │ └── version_range.go │ ├── doc.go │ ├── errors.go │ ├── index_options_builder.go │ ├── index_view.go │ ├── mongo.go │ ├── mongocryptd.go │ ├── options │ │ ├── aggregateoptions.go │ │ ├── autoencryptionoptions.go │ │ ├── bulkwriteoptions.go │ │ ├── changestreamoptions.go │ │ ├── clientencryptionoptions.go │ │ ├── clientoptions.go │ │ ├── collectionoptions.go │ │ ├── countoptions.go │ │ ├── createcollectionoptions.go │ │ ├── datakeyoptions.go │ │ ├── dboptions.go │ │ ├── deleteoptions.go │ │ ├── distinctoptions.go │ │ ├── doc.go │ │ ├── encryptoptions.go │ │ ├── estimatedcountoptions.go │ │ ├── findoptions.go │ │ ├── gridfsoptions.go │ │ ├── indexoptions.go │ │ ├── insertoptions.go │ │ ├── listcollectionsoptions.go │ │ ├── listdatabasesoptions.go │ │ ├── loggeroptions.go │ │ ├── mongooptions.go │ │ ├── replaceoptions.go │ │ ├── rewrapdatakeyoptions.go │ │ ├── runcmdoptions.go │ │ ├── searchindexoptions.go │ │ ├── serverapioptions.go │ │ ├── sessionoptions.go │ │ ├── transactionoptions.go │ │ └── updateoptions.go │ ├── readconcern │ │ └── readconcern.go │ ├── readpref │ │ ├── mode.go │ │ ├── options.go │ │ └── readpref.go │ ├── results.go │ ├── search_index_view.go │ ├── session.go │ ├── single_result.go │ ├── util.go │ └── writeconcern │ │ └── writeconcern.go │ ├── tag │ └── tag.go │ ├── version │ └── version.go │ └── x │ ├── bsonx │ └── bsoncore │ │ ├── array.go │ │ ├── bson_arraybuilder.go │ │ ├── bson_documentbuilder.go │ │ ├── bsoncore.go │ │ ├── doc.go │ │ ├── document.go │ │ ├── document_sequence.go │ │ ├── element.go │ │ ├── tables.go │ │ └── value.go │ └── mongo │ └── driver │ ├── auth │ ├── auth.go │ ├── aws_conv.go │ ├── conversation.go │ ├── cred.go │ ├── creds │ │ ├── awscreds.go │ │ ├── azurecreds.go │ │ ├── doc.go │ │ └── gcpcreds.go │ ├── default.go │ ├── doc.go │ ├── gssapi.go │ ├── gssapi_not_enabled.go │ ├── gssapi_not_supported.go │ ├── internal │ │ └── gssapi │ │ │ ├── gss.go │ │ │ ├── gss_wrapper.c │ │ │ ├── gss_wrapper.h │ │ │ ├── sspi.go │ │ │ ├── sspi_wrapper.c │ │ │ └── sspi_wrapper.h │ ├── mongodbaws.go │ ├── mongodbcr.go │ ├── oidc.go │ ├── plain.go │ ├── sasl.go │ ├── scram.go │ ├── util.go │ └── x509.go │ ├── batch_cursor.go │ ├── batches.go │ ├── compression.go │ ├── connstring │ └── connstring.go │ ├── crypt.go │ ├── dns │ └── dns.go │ ├── driver.go │ ├── errors.go │ ├── legacy.go │ ├── mongocrypt │ ├── binary.go │ ├── errors.go │ ├── errors_not_enabled.go │ ├── mongocrypt.go │ ├── mongocrypt_context.go │ ├── mongocrypt_context_not_enabled.go │ ├── mongocrypt_kms_context.go │ ├── mongocrypt_kms_context_not_enabled.go │ ├── mongocrypt_not_enabled.go │ ├── options │ │ ├── doc.go │ │ ├── mongocrypt_context_options.go │ │ └── mongocrypt_options.go │ └── state.go │ ├── ocsp │ ├── cache.go │ ├── config.go │ ├── ocsp.go │ └── options.go │ ├── operation.go │ ├── operation │ ├── abort_transaction.go │ ├── aggregate.go │ ├── command.go │ ├── commit_transaction.go │ ├── count.go │ ├── create.go │ ├── create_indexes.go │ ├── create_search_indexes.go │ ├── delete.go │ ├── distinct.go │ ├── doc.go │ ├── drop_collection.go │ ├── drop_database.go │ ├── drop_indexes.go │ ├── drop_search_index.go │ ├── end_sessions.go │ ├── errors.go │ ├── find.go │ ├── find_and_modify.go │ ├── hello.go │ ├── insert.go │ ├── listDatabases.go │ ├── list_collections.go │ ├── list_indexes.go │ ├── update.go │ └── update_search_index.go │ ├── operation_exhaust.go │ ├── serverapioptions.go │ ├── session │ ├── client_session.go │ ├── cluster_clock.go │ ├── doc.go │ ├── options.go │ ├── server_session.go │ └── session_pool.go │ ├── topology │ ├── DESIGN.md │ ├── cancellation_listener.go │ ├── connection.go │ ├── connection_legacy.go │ ├── connection_options.go │ ├── diff.go │ ├── errors.go │ ├── fsm.go │ ├── pool.go │ ├── pool_generation_counter.go │ ├── rtt_monitor.go │ ├── server.go │ ├── server_options.go │ ├── tls_connection_source_1_16.go │ ├── tls_connection_source_1_17.go │ ├── topology.go │ └── topology_options.go │ └── wiremessage │ └── wiremessage.go ├── golang.org └── x │ ├── crypto │ ├── LICENSE │ ├── PATENTS │ ├── ocsp │ │ └── ocsp.go │ ├── pbkdf2 │ │ └── pbkdf2.go │ ├── scrypt │ │ └── scrypt.go │ └── sha3 │ │ ├── doc.go │ │ ├── hashes.go │ │ ├── hashes_noasm.go │ │ ├── keccakf.go │ │ ├── keccakf_amd64.go │ │ ├── keccakf_amd64.s │ │ ├── sha3.go │ │ ├── sha3_s390x.go │ │ ├── sha3_s390x.s │ │ ├── shake.go │ │ ├── shake_noasm.go │ │ └── xor.go │ ├── exp │ ├── LICENSE │ ├── PATENTS │ ├── constraints │ │ └── constraints.go │ ├── maps │ │ └── maps.go │ └── slices │ │ ├── cmp.go │ │ ├── slices.go │ │ ├── sort.go │ │ ├── zsortanyfunc.go │ │ └── zsortordered.go │ ├── net │ ├── LICENSE │ ├── PATENTS │ ├── http │ │ └── httpguts │ │ │ ├── guts.go │ │ │ └── httplex.go │ ├── http2 │ │ ├── .gitignore │ │ ├── ascii.go │ │ ├── ciphers.go │ │ ├── client_conn_pool.go │ │ ├── databuffer.go │ │ ├── errors.go │ │ ├── flow.go │ │ ├── frame.go │ │ ├── gotrack.go │ │ ├── h2c │ │ │ └── h2c.go │ │ ├── headermap.go │ │ ├── hpack │ │ │ ├── encode.go │ │ │ ├── hpack.go │ │ │ ├── huffman.go │ │ │ ├── static_table.go │ │ │ └── tables.go │ │ ├── http2.go │ │ ├── pipe.go │ │ ├── server.go │ │ ├── transport.go │ │ ├── write.go │ │ ├── writesched.go │ │ ├── writesched_priority.go │ │ ├── writesched_random.go │ │ └── writesched_roundrobin.go │ └── idna │ │ ├── go118.go │ │ ├── idna10.0.0.go │ │ ├── idna9.0.0.go │ │ ├── pre_go118.go │ │ ├── punycode.go │ │ ├── tables10.0.0.go │ │ ├── tables11.0.0.go │ │ ├── tables12.0.0.go │ │ ├── tables13.0.0.go │ │ ├── tables15.0.0.go │ │ ├── tables9.0.0.go │ │ ├── trie.go │ │ ├── trie12.0.0.go │ │ ├── trie13.0.0.go │ │ └── trieval.go │ ├── sync │ ├── LICENSE │ ├── PATENTS │ ├── errgroup │ │ ├── errgroup.go │ │ ├── go120.go │ │ └── pre_go120.go │ ├── semaphore │ │ └── semaphore.go │ └── singleflight │ │ └── singleflight.go │ ├── sys │ ├── LICENSE │ ├── PATENTS │ ├── cpu │ │ ├── asm_aix_ppc64.s │ │ ├── byteorder.go │ │ ├── cpu.go │ │ ├── cpu_aix.go │ │ ├── cpu_arm.go │ │ ├── cpu_arm64.go │ │ ├── cpu_arm64.s │ │ ├── cpu_gc_arm64.go │ │ ├── cpu_gc_s390x.go │ │ ├── cpu_gc_x86.go │ │ ├── cpu_gccgo_arm64.go │ │ ├── cpu_gccgo_s390x.go │ │ ├── cpu_gccgo_x86.c │ │ ├── cpu_gccgo_x86.go │ │ ├── cpu_linux.go │ │ ├── cpu_linux_arm.go │ │ ├── cpu_linux_arm64.go │ │ ├── cpu_linux_mips64x.go │ │ ├── cpu_linux_noinit.go │ │ ├── cpu_linux_ppc64x.go │ │ ├── cpu_linux_s390x.go │ │ ├── cpu_loong64.go │ │ ├── cpu_mips64x.go │ │ ├── cpu_mipsx.go │ │ ├── cpu_netbsd_arm64.go │ │ ├── cpu_openbsd_arm64.go │ │ ├── cpu_openbsd_arm64.s │ │ ├── cpu_other_arm.go │ │ ├── cpu_other_arm64.go │ │ ├── cpu_other_mips64x.go │ │ ├── cpu_other_ppc64x.go │ │ ├── cpu_other_riscv64.go │ │ ├── cpu_ppc64x.go │ │ ├── cpu_riscv64.go │ │ ├── cpu_s390x.go │ │ ├── cpu_s390x.s │ │ ├── cpu_wasm.go │ │ ├── cpu_x86.go │ │ ├── cpu_x86.s │ │ ├── cpu_zos.go │ │ ├── cpu_zos_s390x.go │ │ ├── endian_big.go │ │ ├── endian_little.go │ │ ├── hwcap_linux.go │ │ ├── parse.go │ │ ├── proc_cpuinfo_linux.go │ │ ├── runtime_auxv.go │ │ ├── runtime_auxv_go121.go │ │ ├── syscall_aix_gccgo.go │ │ └── syscall_aix_ppc64_gc.go │ └── unix │ │ ├── .gitignore │ │ ├── README.md │ │ ├── affinity_linux.go │ │ ├── aliases.go │ │ ├── asm_aix_ppc64.s │ │ ├── asm_bsd_386.s │ │ ├── asm_bsd_amd64.s │ │ ├── asm_bsd_arm.s │ │ ├── asm_bsd_arm64.s │ │ ├── asm_bsd_ppc64.s │ │ ├── asm_bsd_riscv64.s │ │ ├── asm_linux_386.s │ │ ├── asm_linux_amd64.s │ │ ├── asm_linux_arm.s │ │ ├── asm_linux_arm64.s │ │ ├── asm_linux_loong64.s │ │ ├── asm_linux_mips64x.s │ │ ├── asm_linux_mipsx.s │ │ ├── asm_linux_ppc64x.s │ │ ├── asm_linux_riscv64.s │ │ ├── asm_linux_s390x.s │ │ ├── asm_openbsd_mips64.s │ │ ├── asm_solaris_amd64.s │ │ ├── asm_zos_s390x.s │ │ ├── bluetooth_linux.go │ │ ├── bpxsvc_zos.go │ │ ├── bpxsvc_zos.s │ │ ├── cap_freebsd.go │ │ ├── constants.go │ │ ├── dev_aix_ppc.go │ │ ├── dev_aix_ppc64.go │ │ ├── dev_darwin.go │ │ ├── dev_dragonfly.go │ │ ├── dev_freebsd.go │ │ ├── dev_linux.go │ │ ├── dev_netbsd.go │ │ ├── dev_openbsd.go │ │ ├── dev_zos.go │ │ ├── dirent.go │ │ ├── endian_big.go │ │ ├── endian_little.go │ │ ├── env_unix.go │ │ ├── fcntl.go │ │ ├── fcntl_darwin.go │ │ ├── fcntl_linux_32bit.go │ │ ├── fdset.go │ │ ├── gccgo.go │ │ ├── gccgo_c.c │ │ ├── gccgo_linux_amd64.go │ │ ├── ifreq_linux.go │ │ ├── ioctl_linux.go │ │ ├── ioctl_signed.go │ │ ├── ioctl_unsigned.go │ │ ├── ioctl_zos.go │ │ ├── mkall.sh │ │ ├── mkerrors.sh │ │ ├── mmap_nomremap.go │ │ ├── mremap.go │ │ ├── pagesize_unix.go │ │ ├── pledge_openbsd.go │ │ ├── ptrace_darwin.go │ │ ├── ptrace_ios.go │ │ ├── race.go │ │ ├── race0.go │ │ ├── readdirent_getdents.go │ │ ├── readdirent_getdirentries.go │ │ ├── sockcmsg_dragonfly.go │ │ ├── sockcmsg_linux.go │ │ ├── sockcmsg_unix.go │ │ ├── sockcmsg_unix_other.go │ │ ├── sockcmsg_zos.go │ │ ├── symaddr_zos_s390x.s │ │ ├── syscall.go │ │ ├── syscall_aix.go │ │ ├── syscall_aix_ppc.go │ │ ├── syscall_aix_ppc64.go │ │ ├── syscall_bsd.go │ │ ├── syscall_darwin.go │ │ ├── syscall_darwin_amd64.go │ │ ├── syscall_darwin_arm64.go │ │ ├── syscall_darwin_libSystem.go │ │ ├── syscall_dragonfly.go │ │ ├── syscall_dragonfly_amd64.go │ │ ├── syscall_freebsd.go │ │ ├── syscall_freebsd_386.go │ │ ├── syscall_freebsd_amd64.go │ │ ├── syscall_freebsd_arm.go │ │ ├── syscall_freebsd_arm64.go │ │ ├── syscall_freebsd_riscv64.go │ │ ├── syscall_hurd.go │ │ ├── syscall_hurd_386.go │ │ ├── syscall_illumos.go │ │ ├── syscall_linux.go │ │ ├── syscall_linux_386.go │ │ ├── syscall_linux_alarm.go │ │ ├── syscall_linux_amd64.go │ │ ├── syscall_linux_amd64_gc.go │ │ ├── syscall_linux_arm.go │ │ ├── syscall_linux_arm64.go │ │ ├── syscall_linux_gc.go │ │ ├── syscall_linux_gc_386.go │ │ ├── syscall_linux_gc_arm.go │ │ ├── syscall_linux_gccgo_386.go │ │ ├── syscall_linux_gccgo_arm.go │ │ ├── syscall_linux_loong64.go │ │ ├── syscall_linux_mips64x.go │ │ ├── syscall_linux_mipsx.go │ │ ├── syscall_linux_ppc.go │ │ ├── syscall_linux_ppc64x.go │ │ ├── syscall_linux_riscv64.go │ │ ├── syscall_linux_s390x.go │ │ ├── syscall_linux_sparc64.go │ │ ├── syscall_netbsd.go │ │ ├── syscall_netbsd_386.go │ │ ├── syscall_netbsd_amd64.go │ │ ├── syscall_netbsd_arm.go │ │ ├── syscall_netbsd_arm64.go │ │ ├── syscall_openbsd.go │ │ ├── syscall_openbsd_386.go │ │ ├── syscall_openbsd_amd64.go │ │ ├── syscall_openbsd_arm.go │ │ ├── syscall_openbsd_arm64.go │ │ ├── syscall_openbsd_libc.go │ │ ├── syscall_openbsd_mips64.go │ │ ├── syscall_openbsd_ppc64.go │ │ ├── syscall_openbsd_riscv64.go │ │ ├── syscall_solaris.go │ │ ├── syscall_solaris_amd64.go │ │ ├── syscall_unix.go │ │ ├── syscall_unix_gc.go │ │ ├── syscall_unix_gc_ppc64x.go │ │ ├── syscall_zos_s390x.go │ │ ├── sysvshm_linux.go │ │ ├── sysvshm_unix.go │ │ ├── sysvshm_unix_other.go │ │ ├── timestruct.go │ │ ├── unveil_openbsd.go │ │ ├── xattr_bsd.go │ │ ├── zerrors_aix_ppc.go │ │ ├── zerrors_aix_ppc64.go │ │ ├── zerrors_darwin_amd64.go │ │ ├── zerrors_darwin_arm64.go │ │ ├── zerrors_dragonfly_amd64.go │ │ ├── zerrors_freebsd_386.go │ │ ├── zerrors_freebsd_amd64.go │ │ ├── zerrors_freebsd_arm.go │ │ ├── zerrors_freebsd_arm64.go │ │ ├── zerrors_freebsd_riscv64.go │ │ ├── zerrors_linux.go │ │ ├── zerrors_linux_386.go │ │ ├── zerrors_linux_amd64.go │ │ ├── zerrors_linux_arm.go │ │ ├── zerrors_linux_arm64.go │ │ ├── zerrors_linux_loong64.go │ │ ├── zerrors_linux_mips.go │ │ ├── zerrors_linux_mips64.go │ │ ├── zerrors_linux_mips64le.go │ │ ├── zerrors_linux_mipsle.go │ │ ├── zerrors_linux_ppc.go │ │ ├── zerrors_linux_ppc64.go │ │ ├── zerrors_linux_ppc64le.go │ │ ├── zerrors_linux_riscv64.go │ │ ├── zerrors_linux_s390x.go │ │ ├── zerrors_linux_sparc64.go │ │ ├── zerrors_netbsd_386.go │ │ ├── zerrors_netbsd_amd64.go │ │ ├── zerrors_netbsd_arm.go │ │ ├── zerrors_netbsd_arm64.go │ │ ├── zerrors_openbsd_386.go │ │ ├── zerrors_openbsd_amd64.go │ │ ├── zerrors_openbsd_arm.go │ │ ├── zerrors_openbsd_arm64.go │ │ ├── zerrors_openbsd_mips64.go │ │ ├── zerrors_openbsd_ppc64.go │ │ ├── zerrors_openbsd_riscv64.go │ │ ├── zerrors_solaris_amd64.go │ │ ├── zerrors_zos_s390x.go │ │ ├── zptrace_armnn_linux.go │ │ ├── zptrace_linux_arm64.go │ │ ├── zptrace_mipsnn_linux.go │ │ ├── zptrace_mipsnnle_linux.go │ │ ├── zptrace_x86_linux.go │ │ ├── zsymaddr_zos_s390x.s │ │ ├── zsyscall_aix_ppc.go │ │ ├── zsyscall_aix_ppc64.go │ │ ├── zsyscall_aix_ppc64_gc.go │ │ ├── zsyscall_aix_ppc64_gccgo.go │ │ ├── zsyscall_darwin_amd64.go │ │ ├── zsyscall_darwin_amd64.s │ │ ├── zsyscall_darwin_arm64.go │ │ ├── zsyscall_darwin_arm64.s │ │ ├── zsyscall_dragonfly_amd64.go │ │ ├── zsyscall_freebsd_386.go │ │ ├── zsyscall_freebsd_amd64.go │ │ ├── zsyscall_freebsd_arm.go │ │ ├── zsyscall_freebsd_arm64.go │ │ ├── zsyscall_freebsd_riscv64.go │ │ ├── zsyscall_illumos_amd64.go │ │ ├── zsyscall_linux.go │ │ ├── zsyscall_linux_386.go │ │ ├── zsyscall_linux_amd64.go │ │ ├── zsyscall_linux_arm.go │ │ ├── zsyscall_linux_arm64.go │ │ ├── zsyscall_linux_loong64.go │ │ ├── zsyscall_linux_mips.go │ │ ├── zsyscall_linux_mips64.go │ │ ├── zsyscall_linux_mips64le.go │ │ ├── zsyscall_linux_mipsle.go │ │ ├── zsyscall_linux_ppc.go │ │ ├── zsyscall_linux_ppc64.go │ │ ├── zsyscall_linux_ppc64le.go │ │ ├── zsyscall_linux_riscv64.go │ │ ├── zsyscall_linux_s390x.go │ │ ├── zsyscall_linux_sparc64.go │ │ ├── zsyscall_netbsd_386.go │ │ ├── zsyscall_netbsd_amd64.go │ │ ├── zsyscall_netbsd_arm.go │ │ ├── zsyscall_netbsd_arm64.go │ │ ├── zsyscall_openbsd_386.go │ │ ├── zsyscall_openbsd_386.s │ │ ├── zsyscall_openbsd_amd64.go │ │ ├── zsyscall_openbsd_amd64.s │ │ ├── zsyscall_openbsd_arm.go │ │ ├── zsyscall_openbsd_arm.s │ │ ├── zsyscall_openbsd_arm64.go │ │ ├── zsyscall_openbsd_arm64.s │ │ ├── zsyscall_openbsd_mips64.go │ │ ├── zsyscall_openbsd_mips64.s │ │ ├── zsyscall_openbsd_ppc64.go │ │ ├── zsyscall_openbsd_ppc64.s │ │ ├── zsyscall_openbsd_riscv64.go │ │ ├── zsyscall_openbsd_riscv64.s │ │ ├── zsyscall_solaris_amd64.go │ │ ├── zsyscall_zos_s390x.go │ │ ├── zsysctl_openbsd_386.go │ │ ├── zsysctl_openbsd_amd64.go │ │ ├── zsysctl_openbsd_arm.go │ │ ├── zsysctl_openbsd_arm64.go │ │ ├── zsysctl_openbsd_mips64.go │ │ ├── zsysctl_openbsd_ppc64.go │ │ ├── zsysctl_openbsd_riscv64.go │ │ ├── zsysnum_darwin_amd64.go │ │ ├── zsysnum_darwin_arm64.go │ │ ├── zsysnum_dragonfly_amd64.go │ │ ├── zsysnum_freebsd_386.go │ │ ├── zsysnum_freebsd_amd64.go │ │ ├── zsysnum_freebsd_arm.go │ │ ├── zsysnum_freebsd_arm64.go │ │ ├── zsysnum_freebsd_riscv64.go │ │ ├── zsysnum_linux_386.go │ │ ├── zsysnum_linux_amd64.go │ │ ├── zsysnum_linux_arm.go │ │ ├── zsysnum_linux_arm64.go │ │ ├── zsysnum_linux_loong64.go │ │ ├── zsysnum_linux_mips.go │ │ ├── zsysnum_linux_mips64.go │ │ ├── zsysnum_linux_mips64le.go │ │ ├── zsysnum_linux_mipsle.go │ │ ├── zsysnum_linux_ppc.go │ │ ├── zsysnum_linux_ppc64.go │ │ ├── zsysnum_linux_ppc64le.go │ │ ├── zsysnum_linux_riscv64.go │ │ ├── zsysnum_linux_s390x.go │ │ ├── zsysnum_linux_sparc64.go │ │ ├── zsysnum_netbsd_386.go │ │ ├── zsysnum_netbsd_amd64.go │ │ ├── zsysnum_netbsd_arm.go │ │ ├── zsysnum_netbsd_arm64.go │ │ ├── zsysnum_openbsd_386.go │ │ ├── zsysnum_openbsd_amd64.go │ │ ├── zsysnum_openbsd_arm.go │ │ ├── zsysnum_openbsd_arm64.go │ │ ├── zsysnum_openbsd_mips64.go │ │ ├── zsysnum_openbsd_ppc64.go │ │ ├── zsysnum_openbsd_riscv64.go │ │ ├── zsysnum_zos_s390x.go │ │ ├── ztypes_aix_ppc.go │ │ ├── ztypes_aix_ppc64.go │ │ ├── ztypes_darwin_amd64.go │ │ ├── ztypes_darwin_arm64.go │ │ ├── ztypes_dragonfly_amd64.go │ │ ├── ztypes_freebsd_386.go │ │ ├── ztypes_freebsd_amd64.go │ │ ├── ztypes_freebsd_arm.go │ │ ├── ztypes_freebsd_arm64.go │ │ ├── ztypes_freebsd_riscv64.go │ │ ├── ztypes_linux.go │ │ ├── ztypes_linux_386.go │ │ ├── ztypes_linux_amd64.go │ │ ├── ztypes_linux_arm.go │ │ ├── ztypes_linux_arm64.go │ │ ├── ztypes_linux_loong64.go │ │ ├── ztypes_linux_mips.go │ │ ├── ztypes_linux_mips64.go │ │ ├── ztypes_linux_mips64le.go │ │ ├── ztypes_linux_mipsle.go │ │ ├── ztypes_linux_ppc.go │ │ ├── ztypes_linux_ppc64.go │ │ ├── ztypes_linux_ppc64le.go │ │ ├── ztypes_linux_riscv64.go │ │ ├── ztypes_linux_s390x.go │ │ ├── ztypes_linux_sparc64.go │ │ ├── ztypes_netbsd_386.go │ │ ├── ztypes_netbsd_amd64.go │ │ ├── ztypes_netbsd_arm.go │ │ ├── ztypes_netbsd_arm64.go │ │ ├── ztypes_openbsd_386.go │ │ ├── ztypes_openbsd_amd64.go │ │ ├── ztypes_openbsd_arm.go │ │ ├── ztypes_openbsd_arm64.go │ │ ├── ztypes_openbsd_mips64.go │ │ ├── ztypes_openbsd_ppc64.go │ │ ├── ztypes_openbsd_riscv64.go │ │ ├── ztypes_solaris_amd64.go │ │ └── ztypes_zos_s390x.go │ └── text │ ├── LICENSE │ ├── PATENTS │ ├── cases │ ├── cases.go │ ├── context.go │ ├── fold.go │ ├── icu.go │ ├── info.go │ ├── map.go │ ├── tables10.0.0.go │ ├── tables11.0.0.go │ ├── tables12.0.0.go │ ├── tables13.0.0.go │ ├── tables15.0.0.go │ ├── tables9.0.0.go │ └── trieval.go │ ├── internal │ ├── internal.go │ ├── language │ │ ├── common.go │ │ ├── compact.go │ │ ├── compact │ │ │ ├── compact.go │ │ │ ├── language.go │ │ │ ├── parents.go │ │ │ ├── tables.go │ │ │ └── tags.go │ │ ├── compose.go │ │ ├── coverage.go │ │ ├── language.go │ │ ├── lookup.go │ │ ├── match.go │ │ ├── parse.go │ │ ├── tables.go │ │ └── tags.go │ ├── match.go │ └── tag │ │ └── tag.go │ ├── language │ ├── coverage.go │ ├── doc.go │ ├── language.go │ ├── match.go │ ├── parse.go │ ├── tables.go │ └── tags.go │ ├── secure │ └── bidirule │ │ ├── bidirule.go │ │ ├── bidirule10.0.0.go │ │ └── bidirule9.0.0.go │ ├── transform │ └── transform.go │ └── unicode │ ├── bidi │ ├── bidi.go │ ├── bracket.go │ ├── core.go │ ├── prop.go │ ├── tables10.0.0.go │ ├── tables11.0.0.go │ ├── tables12.0.0.go │ ├── tables13.0.0.go │ ├── tables15.0.0.go │ ├── tables9.0.0.go │ └── trieval.go │ └── norm │ ├── composition.go │ ├── forminfo.go │ ├── input.go │ ├── iter.go │ ├── normalize.go │ ├── readwriter.go │ ├── tables10.0.0.go │ ├── tables11.0.0.go │ ├── tables12.0.0.go │ ├── tables13.0.0.go │ ├── tables15.0.0.go │ ├── tables9.0.0.go │ ├── transform.go │ └── trie.go ├── google.golang.org └── protobuf │ ├── AUTHORS │ ├── CONTRIBUTORS │ ├── LICENSE │ ├── PATENTS │ ├── encoding │ └── protowire │ │ └── wire.go │ ├── internal │ ├── detrand │ │ └── rand.go │ ├── encoding │ │ └── messageset │ │ │ └── messageset.go │ ├── errors │ │ ├── errors.go │ │ ├── is_go112.go │ │ └── is_go113.go │ ├── flags │ │ ├── flags.go │ │ ├── proto_legacy_disable.go │ │ └── proto_legacy_enable.go │ ├── genid │ │ ├── any_gen.go │ │ ├── api_gen.go │ │ ├── descriptor_gen.go │ │ ├── doc.go │ │ ├── duration_gen.go │ │ ├── empty_gen.go │ │ ├── field_mask_gen.go │ │ ├── goname.go │ │ ├── map_entry.go │ │ ├── source_context_gen.go │ │ ├── struct_gen.go │ │ ├── timestamp_gen.go │ │ ├── type_gen.go │ │ ├── wrappers.go │ │ └── wrappers_gen.go │ ├── order │ │ ├── order.go │ │ └── range.go │ ├── pragma │ │ └── pragma.go │ └── strs │ │ ├── strings.go │ │ ├── strings_pure.go │ │ └── strings_unsafe.go │ ├── proto │ ├── checkinit.go │ ├── decode.go │ ├── decode_gen.go │ ├── doc.go │ ├── encode.go │ ├── encode_gen.go │ ├── equal.go │ ├── extension.go │ ├── merge.go │ ├── messageset.go │ ├── proto.go │ ├── proto_methods.go │ ├── proto_reflect.go │ ├── reset.go │ ├── size.go │ ├── size_gen.go │ └── wrappers.go │ ├── reflect │ ├── protoreflect │ │ ├── methods.go │ │ ├── proto.go │ │ ├── source.go │ │ ├── source_gen.go │ │ ├── type.go │ │ ├── value.go │ │ ├── value_pure.go │ │ ├── value_union.go │ │ └── value_unsafe.go │ └── protoregistry │ │ └── registry.go │ └── runtime │ └── protoiface │ ├── legacy.go │ └── methods.go ├── gopkg.in ├── natefinch │ └── lumberjack.v2 │ │ ├── .gitignore │ │ ├── .travis.yml │ │ ├── LICENSE │ │ ├── README.md │ │ ├── chown.go │ │ ├── chown_linux.go │ │ └── lumberjack.go ├── yaml.v2 │ ├── .travis.yml │ ├── LICENSE │ ├── LICENSE.libyaml │ ├── NOTICE │ ├── README.md │ ├── apic.go │ ├── decode.go │ ├── emitterc.go │ ├── encode.go │ ├── parserc.go │ ├── readerc.go │ ├── resolve.go │ ├── scannerc.go │ ├── sorter.go │ ├── writerc.go │ ├── yaml.go │ ├── yamlh.go │ └── yamlprivateh.go └── yaml.v3 │ ├── LICENSE │ ├── NOTICE │ ├── README.md │ ├── apic.go │ ├── decode.go │ ├── emitterc.go │ ├── encode.go │ ├── parserc.go │ ├── readerc.go │ ├── resolve.go │ ├── scannerc.go │ ├── sorter.go │ ├── writerc.go │ ├── yaml.go │ ├── yamlh.go │ └── yamlprivateh.go └── modules.txt /.github/workflows/lint.yml: -------------------------------------------------------------------------------- 1 | on: 2 | push: 3 | branches: 4 | - '*' 5 | tags-ignore: 6 | - '*' 7 | pull_request: 8 | 9 | permissions: 10 | contents: read 11 | # Optional: allow read access to pull request. Use with `only-new-issues` option. 12 | # pull-requests: read 13 | 14 | jobs: 15 | golangci: 16 | name: lint 17 | runs-on: ubuntu-latest 18 | steps: 19 | - uses: actions/checkout@v4 20 | - uses: actions/setup-go@v5 21 | with: 22 | go-version: stable 23 | - name: golangci-lint 24 | uses: golangci/golangci-lint-action@v7.0.0 25 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | dev-bin/ 2 | golangci-lint 3 | migration_verifier 4 | internal/verifier/mongodb_exec/ 5 | verifier_expansion.yml 6 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Copyright 2014 MongoDB, Inc. 2 | 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, software 10 | distributed under the License is distributed on an "AS IS" BASIS, 11 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | See the License for the specific language governing permissions and 13 | limitations under the License. 14 | -------------------------------------------------------------------------------- /build.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | commit=$(git show --no-patch --format='%H') 4 | buildTime=$(date -u) 5 | 6 | go build -ldflags="-X 'main.Revision=$commit' -X 'main.BuildTime=$buildTime'" main/migration_verifier.go 7 | -------------------------------------------------------------------------------- /contextplus/unit_test.go: -------------------------------------------------------------------------------- 1 | package contextplus 2 | 3 | import ( 4 | "testing" 5 | 6 | "github.com/stretchr/testify/suite" 7 | ) 8 | 9 | type UnitTestSuite struct { 10 | suite.Suite 11 | } 12 | 13 | func TestUnitTestSuite(t *testing.T) { 14 | ts := new(UnitTestSuite) 15 | suite.Run(t, ts) 16 | } 17 | -------------------------------------------------------------------------------- /evergreen/go_lint.py: -------------------------------------------------------------------------------- 1 | import subprocess 2 | 3 | # TODO: this can't be right, maybe someone on evergreen can correct this 4 | subprocess.run( 5 | "curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b .", 6 | shell=True, 7 | check=True) 8 | subprocess.run("./golangci-lint run", shell=True, check=True) 9 | -------------------------------------------------------------------------------- /evergreen/go_test.py: -------------------------------------------------------------------------------- 1 | import os 2 | import subprocess 3 | 4 | try: 5 | mongodb_distro = "mongodb-" + os.environ["OS"] + "-" + os.environ[ 6 | "ARCH"] + "-" + os.environ["PLATFORM"] 7 | except: 8 | print("Failed to get required options needed to run the test") 9 | raise 10 | else: 11 | print(f"Running go test with MONGODB_DISTRO={mongodb_distro}") 12 | 13 | env_with_distro = os.environ.copy() 14 | env_with_distro["MONGODB_DISTRO"] = mongodb_distro 15 | 16 | subprocess.run("go test -v ./...", shell=True, check=True, env=env_with_distro) 17 | -------------------------------------------------------------------------------- /evergreen/prelude_db_contrib_tool.sh: -------------------------------------------------------------------------------- 1 | function setup_db_contrib_tool_venv { 2 | 3 | mkdir ${workdir}/pipx 4 | export PIPX_HOME="${workdir}/pipx" 5 | export PIPX_BIN_DIR="${workdir}/pipx/bin" 6 | export PATH="$PATH:$PIPX_BIN_DIR" 7 | 8 | python -m pip --disable-pip-version-check install "pip==21.0.1" "wheel==0.37.0" || exit 1 9 | python -m pip --disable-pip-version-check install "pipx" || exit 1 10 | pipx install "db-contrib-tool==0.4.5" || exit 1 11 | } 12 | -------------------------------------------------------------------------------- /evergreen/prelude_python.sh: -------------------------------------------------------------------------------- 1 | if [ "Windows_NT" = "$OS" ]; then 2 | python='/cygdrive/c/python/python37/python.exe' 3 | else 4 | if [ -f /opt/mongodbtoolchain/v3/bin/python3 ]; then 5 | python="/opt/mongodbtoolchain/v3/bin/python3" 6 | elif [ -f "$(which python3)" ]; then 7 | echo "Could not find mongodbtoolchain python, using system python $(which python3)" > 2 8 | python=$(which python3) 9 | else 10 | echo "Could not find python3." > 2 11 | return 1 12 | fi 13 | fi 14 | -------------------------------------------------------------------------------- /evergreen/run_python_script.sh: -------------------------------------------------------------------------------- 1 | unset workdir 2 | DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" > /dev/null 2>&1 && pwd)" 3 | . "$DIR/prelude.sh" 4 | 5 | set -o errexit 6 | set -o verbose 7 | 8 | eval "${PREPARE_SHELL}" 9 | PATH=$PATH:$HOME 10 | 11 | activate_venv 12 | 13 | $python $@ 14 | -------------------------------------------------------------------------------- /gorules/interface_any.go: -------------------------------------------------------------------------------- 1 | //go:build ruleguard 2 | // +build ruleguard 3 | 4 | package gorules 5 | 6 | import "github.com/quasilyte/go-ruleguard/dsl" 7 | 8 | func NoRawInterface(m dsl.Matcher) { 9 | m.Match("interface{}"). 10 | Report("Avoid $$; prefer `any`."). 11 | Suggest("any") 12 | } 13 | -------------------------------------------------------------------------------- /gorules/zerolog_interface_any.go: -------------------------------------------------------------------------------- 1 | //go:build ruleguard 2 | // +build ruleguard 3 | 4 | package gorules 5 | 6 | import "github.com/quasilyte/go-ruleguard/dsl" 7 | 8 | func NoZerologInterface(m dsl.Matcher) { 9 | m.Import("github.com/rs/zerolog") 10 | 11 | m.Match("$v.Interface"). 12 | Where(m["v"].Type.Is("*zerolog.Event")). 13 | Report("Avoid Interface(); use Any() instead.") 14 | } 15 | -------------------------------------------------------------------------------- /internal/retry/constants.go: -------------------------------------------------------------------------------- 1 | package retry 2 | 3 | import "time" 4 | 5 | const ( 6 | // DefaultDurationLimit is the default time limit for all retries. 7 | DefaultDurationLimit = 10 * time.Minute 8 | 9 | // Constants for spacing out the retry attempts. 10 | // See: https://en.wikipedia.org/wiki/Exponential_backoff 11 | // 12 | // The sequence, in seconds, is: 1, 2, 4, 8, 16, 16, 16, ... 13 | minSleepTime = 1 * time.Second 14 | maxSleepTime = 16 * time.Second 15 | sleepTimeMultiplier = 2 16 | ) 17 | -------------------------------------------------------------------------------- /internal/types/types_test.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | import ( 4 | "reflect" 5 | "testing" 6 | 7 | "github.com/stretchr/testify/suite" 8 | ) 9 | 10 | type UnitTestSuite struct { 11 | suite.Suite 12 | } 13 | 14 | func TestUnitTestSuite(t *testing.T) { 15 | ts := new(UnitTestSuite) 16 | suite.Run(t, ts) 17 | } 18 | 19 | func (s *UnitTestSuite) TestToNumericTypeOf() { 20 | foo := int16(234) 21 | 22 | bar := ToNumericTypeOf(int64(1), foo) 23 | 24 | s.Assert().Equal(reflect.TypeOf(foo), reflect.TypeOf(bar), "it works on int16") 25 | 26 | fooFloat := 234.467 27 | barFloat := ToNumericTypeOf(int64(1), fooFloat) 28 | 29 | s.Assert().Equal(reflect.TypeOf(fooFloat), reflect.TypeOf(barFloat), "it works on float-y") 30 | } 31 | -------------------------------------------------------------------------------- /internal/util/agg.go: -------------------------------------------------------------------------------- 1 | package util 2 | 3 | import ( 4 | "github.com/10gen/migration-verifier/mmongo" 5 | "github.com/samber/lo" 6 | "go.mongodb.org/mongo-driver/bson" 7 | ) 8 | 9 | // ExcludePrefixesQuery returns a document that represents a query 10 | // (not aggregation!) that matches documents where the indicated field 11 | // DOES NOT have any of the indicated prefixes. 12 | // 13 | // This is useful, e.g., in $match aggregation phases to exclude change 14 | // events for system namespaces. 15 | func ExcludePrefixesQuery(fieldName string, prefixes []string) bson.D { 16 | return bson.D{ 17 | {"$expr", bson.D{{"$not", bson.D{ 18 | {"$or", lo.Map( 19 | prefixes, 20 | func(prefix string, _ int) bson.D { 21 | return mmongo.StartsWithAgg("$"+fieldName, prefix) 22 | }, 23 | )}, 24 | }}}}, 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /internal/util/cluster_time.go: -------------------------------------------------------------------------------- 1 | package util 2 | 3 | import ( 4 | "github.com/pkg/errors" 5 | "go.mongodb.org/mongo-driver/bson" 6 | "go.mongodb.org/mongo-driver/bson/primitive" 7 | "go.mongodb.org/mongo-driver/mongo" 8 | ) 9 | 10 | func GetClusterTimeFromSession(sess mongo.Session) (primitive.Timestamp, error) { 11 | ctStruct := struct { 12 | ClusterTime struct { 13 | ClusterTime primitive.Timestamp `bson:"clusterTime"` 14 | } `bson:"$clusterTime"` 15 | }{} 16 | 17 | clusterTimeRaw := sess.ClusterTime() 18 | err := bson.Unmarshal(sess.ClusterTime(), &ctStruct) 19 | if err != nil { 20 | return primitive.Timestamp{}, errors.Wrapf(err, "failed to find clusterTime in session cluster time document (%v)", clusterTimeRaw) 21 | } 22 | 23 | return ctStruct.ClusterTime.ClusterTime, nil 24 | } 25 | -------------------------------------------------------------------------------- /internal/util/eventual_test.go: -------------------------------------------------------------------------------- 1 | package util 2 | 3 | import ( 4 | "time" 5 | ) 6 | 7 | func (s *UnitTestSuite) TestEventual() { 8 | eventual := NewEventual[int]() 9 | 10 | s.Assert().Panics( 11 | func() { eventual.Get() }, 12 | "Get() should panic before the value is set", 13 | ) 14 | 15 | select { 16 | case <-eventual.Ready(): 17 | s.Require().Fail("should not be ready") 18 | case <-time.NewTimer(time.Second).C: 19 | } 20 | 21 | eventual.Set(123) 22 | 23 | select { 24 | case <-eventual.Ready(): 25 | case <-time.NewTimer(time.Second).C: 26 | s.Require().Fail("should be ready") 27 | } 28 | 29 | s.Assert().Equal( 30 | 123, 31 | eventual.Get(), 32 | "Get() should return the value", 33 | ) 34 | } 35 | -------------------------------------------------------------------------------- /internal/util/invariant.go: -------------------------------------------------------------------------------- 1 | package util 2 | 3 | import ( 4 | "log" 5 | 6 | "github.com/10gen/migration-verifier/internal/logger" 7 | ) 8 | 9 | // Invariant asserts the predicate is true, and if not, logs the message and exits. 10 | func Invariant(logger *logger.Logger, predicate bool, message string, args ...any) { 11 | if !predicate { 12 | if logger == nil { 13 | log.Fatalf(message, args...) 14 | } 15 | logger.Fatal().Msgf(message, args...) 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /internal/util/math.go: -------------------------------------------------------------------------------- 1 | package util 2 | 3 | import "github.com/10gen/migration-verifier/internal/types" 4 | 5 | // Divide is syntactic sugar around float64(numerator) / float64(denominator). 6 | func Divide[N types.RealNumber, D types.RealNumber](numerator N, denominator D) float64 { 7 | return float64(numerator) / float64(denominator) 8 | } 9 | -------------------------------------------------------------------------------- /internal/verifier/check_test.go: -------------------------------------------------------------------------------- 1 | package verifier 2 | 3 | func (suite *IntegrationTestSuite) TestPersistedMetadataVersionMismatch() { 4 | ctx := suite.Context() 5 | 6 | verifier := suite.BuildVerifier() 7 | verifier.SetNamespaceMap() 8 | 9 | genColl := verifier.metaClient. 10 | Database(verifier.metaDBName). 11 | Collection(generationCollName) 12 | 13 | _, err := genColl.InsertOne( 14 | ctx, 15 | generationDoc{ 16 | MetadataVersion: verifierMetadataVersion - 1, 17 | }, 18 | ) 19 | suite.Require().NoError(err, "should write old generation doc") 20 | 21 | runner := RunVerifierCheck(ctx, suite.T(), verifier) 22 | err = runner.AwaitGenerationEnd() 23 | 24 | mme := metadataMismatchErr{} 25 | suite.Require().ErrorAs(err, &mme) 26 | } 27 | -------------------------------------------------------------------------------- /internal/verifier/metadata.go: -------------------------------------------------------------------------------- 1 | package verifier 2 | 3 | // Metadata version history: 4 | // 1: Defined metadata version. 5 | // 2: Split failed-task discrepancies into separate collection. 6 | 7 | const verifierMetadataVersion = 2 8 | -------------------------------------------------------------------------------- /mmongo/agg.go: -------------------------------------------------------------------------------- 1 | package mmongo 2 | 3 | import "go.mongodb.org/mongo-driver/bson" 4 | 5 | // StartsWithAgg returns an aggregation expression that indicates whether 6 | // the referent field begins with the “besought” string. 7 | // 8 | // Equivalent to JavaScript String.prototype.startsWith(besought). 9 | func StartsWithAgg(fieldRef string, besought string) bson.D { 10 | return bson.D{ 11 | {"$eq", bson.A{ 12 | 0, 13 | bson.D{{"$indexOfCP", bson.A{ 14 | fieldRef, 15 | besought, 16 | 0, // start scanning at index 0 17 | 1, // stop scanning at index 1 18 | }}}, 19 | }}, 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /mmongo/error.go: -------------------------------------------------------------------------------- 1 | package mmongo 2 | 3 | import ( 4 | "github.com/pkg/errors" 5 | "go.mongodb.org/mongo-driver/mongo" 6 | ) 7 | 8 | // ErrorHasCode returns true if (and only if) this error is a 9 | // mongo.ServerError that contains the given error code. 10 | func ErrorHasCode[T ~int](err error, code T) bool { 11 | var serverError mongo.ServerError 12 | 13 | return errors.As(err, &serverError) && serverError.HasErrorCode(int(code)) 14 | } 15 | -------------------------------------------------------------------------------- /mslices/slices.go: -------------------------------------------------------------------------------- 1 | package mslices 2 | 3 | // This package complements the Go standard library’s package of the 4 | // same name with broadly-useful tools that the standard library lacks. 5 | 6 | // Of returns a slice out of the given arguments. It’s syntactic sugar 7 | // to capitalize on Go’s type inference, similar to 8 | // [this declined feature proposal](https://github.com/golang/go/issues/47709). 9 | func Of[T any](pieces ...T) []T { 10 | return append([]T{}, pieces...) 11 | } 12 | 13 | // ToMap outputs a map that “indexes” the given slice. 14 | func ToMap[S ~[]E, E any, K comparable](s S, cb func(el E) K) map[K]E { 15 | theMap := make(map[K]E, len(s)) 16 | 17 | for _, el := range s { 18 | theMap[cb(el)] = el 19 | } 20 | 21 | return theMap 22 | } 23 | -------------------------------------------------------------------------------- /mstrings/builder.go: -------------------------------------------------------------------------------- 1 | package mstrings 2 | 3 | import ( 4 | "strings" 5 | "sync" 6 | ) 7 | 8 | // SyncBuilder is a race-safe version of the standard library’s strings.Builder. 9 | // As of this writing it doesn’t implement all of the standard library’s logic. 10 | type SyncBuilder struct { 11 | mutex sync.RWMutex 12 | builder strings.Builder 13 | } 14 | 15 | func (b *SyncBuilder) String() string { 16 | b.mutex.RLock() 17 | defer b.mutex.RUnlock() 18 | 19 | return b.builder.String() 20 | } 21 | 22 | func (b *SyncBuilder) Write(p []byte) (int, error) { 23 | b.mutex.Lock() 24 | defer b.mutex.Unlock() 25 | 26 | return b.builder.Write(p) 27 | } 28 | -------------------------------------------------------------------------------- /msync/dataguard_test.go: -------------------------------------------------------------------------------- 1 | package msync 2 | 3 | import ( 4 | "sync" 5 | "testing" 6 | 7 | "github.com/stretchr/testify/suite" 8 | ) 9 | 10 | type unitTestSuite struct { 11 | suite.Suite 12 | } 13 | 14 | func TestUnitTestSuite(t *testing.T) { 15 | suite.Run(t, &unitTestSuite{}) 16 | } 17 | 18 | func (s *unitTestSuite) TestDataGuard() { 19 | l := NewDataGuard(42) 20 | 21 | var wg sync.WaitGroup 22 | for i := 0; i < 100; i++ { 23 | var delta int 24 | if i%2 == 0 { 25 | delta = 2 26 | } else { 27 | delta = -1 28 | } 29 | 30 | wg.Add(1) 31 | go func() { 32 | defer wg.Done() 33 | l.Store(func(v int) int { 34 | return v + delta 35 | }) 36 | }() 37 | } 38 | wg.Wait() 39 | 40 | l.Load(func(v int) { 41 | s.Require().Equal(92, v) 42 | }) 43 | } 44 | -------------------------------------------------------------------------------- /option/json.go: -------------------------------------------------------------------------------- 1 | package option 2 | 3 | import ( 4 | "bytes" 5 | "encoding/json" 6 | ) 7 | 8 | var _ json.Marshaler = &Option[int]{} 9 | var _ json.Unmarshaler = &Option[int]{} 10 | 11 | // MarshalJSON encodes Option into json. 12 | func (o Option[T]) MarshalJSON() ([]byte, error) { 13 | val, exists := o.Get() 14 | if exists { 15 | return json.Marshal(val) 16 | } 17 | 18 | return json.Marshal(nil) 19 | } 20 | 21 | // UnmarshalJSON decodes Option from json. 22 | func (o *Option[T]) UnmarshalJSON(b []byte) error { 23 | if bytes.Equal(b, []byte("null")) { 24 | o.val = nil 25 | } else { 26 | val := *new(T) 27 | 28 | err := json.Unmarshal(b, &val) 29 | if err != nil { 30 | return err 31 | } 32 | 33 | o.val = &val 34 | } 35 | 36 | return nil 37 | } 38 | -------------------------------------------------------------------------------- /option/validate.go: -------------------------------------------------------------------------------- 1 | package option 2 | 3 | import ( 4 | "reflect" 5 | 6 | mapset "github.com/deckarep/golang-set/v2" 7 | ) 8 | 9 | var nilable = mapset.NewThreadUnsafeSet( 10 | reflect.Chan, 11 | reflect.Func, 12 | reflect.Interface, 13 | reflect.Map, 14 | reflect.Pointer, 15 | reflect.Slice, 16 | ) 17 | 18 | func isNil(val any) bool { 19 | if val == nil { 20 | return true 21 | } 22 | 23 | if nilable.Contains(reflect.TypeOf(val).Kind()) { 24 | return reflect.ValueOf(val).IsNil() 25 | } 26 | 27 | return false 28 | } 29 | -------------------------------------------------------------------------------- /precious.toml: -------------------------------------------------------------------------------- 1 | # When adding new tidiers, consider what labels it should have. If it's fast, set labels like this: 2 | # 3 | # labels = [ "default", "fast-tidy" ] 4 | # 5 | # "Fast" here means anything less than 0.1s. These tidiers are intended to be invoked frequently, 6 | # for example from editors on save. Slower tidiers should only be invoked manually. 7 | 8 | exclude = "vendor/**" 9 | 10 | [commands.goimports] 11 | type = "tidy" 12 | include = "**/*.go" 13 | cmd = [ "$PRECIOUS_ROOT/dev-bin/goimports", "-w" ] 14 | ok-exit-codes = [0] 15 | labels = [ "default", "fast-tidy" ] 16 | -------------------------------------------------------------------------------- /vendor/github.com/BurntSushi/toml/.gitignore: -------------------------------------------------------------------------------- 1 | TAGS 2 | tags 3 | .*.swp 4 | tomlcheck/tomlcheck 5 | toml.test 6 | -------------------------------------------------------------------------------- /vendor/github.com/BurntSushi/toml/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | go: 3 | - 1.1 4 | - 1.2 5 | - 1.3 6 | - 1.4 7 | - 1.5 8 | - 1.6 9 | - tip 10 | install: 11 | - go install ./... 12 | - go get github.com/BurntSushi/toml-test 13 | script: 14 | - export PATH="$PATH:$HOME/gopath/bin" 15 | - make test 16 | -------------------------------------------------------------------------------- /vendor/github.com/BurntSushi/toml/COMPATIBLE: -------------------------------------------------------------------------------- 1 | Compatible with TOML version 2 | [v0.4.0](https://github.com/toml-lang/toml/blob/v0.4.0/versions/en/toml-v0.4.0.md) 3 | 4 | -------------------------------------------------------------------------------- /vendor/github.com/BurntSushi/toml/Makefile: -------------------------------------------------------------------------------- 1 | install: 2 | go install ./... 3 | 4 | test: install 5 | go test -v 6 | toml-test toml-test-decoder 7 | toml-test -encoder toml-test-encoder 8 | 9 | fmt: 10 | gofmt -w *.go */*.go 11 | colcheck *.go */*.go 12 | 13 | tags: 14 | find ./ -name '*.go' -print0 | xargs -0 gotags > TAGS 15 | 16 | push: 17 | git push origin master 18 | git push github master 19 | 20 | -------------------------------------------------------------------------------- /vendor/github.com/BurntSushi/toml/encoding_types.go: -------------------------------------------------------------------------------- 1 | // +build go1.2 2 | 3 | package toml 4 | 5 | // In order to support Go 1.1, we define our own TextMarshaler and 6 | // TextUnmarshaler types. For Go 1.2+, we just alias them with the 7 | // standard library interfaces. 8 | 9 | import ( 10 | "encoding" 11 | ) 12 | 13 | // TextMarshaler is a synonym for encoding.TextMarshaler. It is defined here 14 | // so that Go 1.1 can be supported. 15 | type TextMarshaler encoding.TextMarshaler 16 | 17 | // TextUnmarshaler is a synonym for encoding.TextUnmarshaler. It is defined 18 | // here so that Go 1.1 can be supported. 19 | type TextUnmarshaler encoding.TextUnmarshaler 20 | -------------------------------------------------------------------------------- /vendor/github.com/BurntSushi/toml/encoding_types_1.1.go: -------------------------------------------------------------------------------- 1 | // +build !go1.2 2 | 3 | package toml 4 | 5 | // These interfaces were introduced in Go 1.2, so we add them manually when 6 | // compiling for Go 1.1. 7 | 8 | // TextMarshaler is a synonym for encoding.TextMarshaler. It is defined here 9 | // so that Go 1.1 can be supported. 10 | type TextMarshaler interface { 11 | MarshalText() (text []byte, err error) 12 | } 13 | 14 | // TextUnmarshaler is a synonym for encoding.TextUnmarshaler. It is defined 15 | // here so that Go 1.1 can be supported. 16 | type TextUnmarshaler interface { 17 | UnmarshalText(text []byte) error 18 | } 19 | -------------------------------------------------------------------------------- /vendor/github.com/BurntSushi/toml/session.vim: -------------------------------------------------------------------------------- 1 | au BufWritePost *.go silent!make tags > /dev/null 2>&1 2 | -------------------------------------------------------------------------------- /vendor/github.com/cespare/permute/v2/README.md: -------------------------------------------------------------------------------- 1 | # permute 2 | 3 | [![Go Reference](https://pkg.go.dev/badge/github.com/cespare/permute.svg)](https://pkg.go.dev/github.com/cespare/permute) 4 | 5 | Permute is a Go package for generating permutations. 6 | -------------------------------------------------------------------------------- /vendor/github.com/cpuguy83/go-md2man/v2/md2man/md2man.go: -------------------------------------------------------------------------------- 1 | package md2man 2 | 3 | import ( 4 | "github.com/russross/blackfriday/v2" 5 | ) 6 | 7 | // Render converts a markdown document into a roff formatted document. 8 | func Render(doc []byte) []byte { 9 | renderer := NewRoffRenderer() 10 | 11 | return blackfriday.Run(doc, 12 | []blackfriday.Option{blackfriday.WithRenderer(renderer), 13 | blackfriday.WithExtensions(renderer.GetExtensions())}...) 14 | } 15 | -------------------------------------------------------------------------------- /vendor/github.com/davecgh/go-spew/LICENSE: -------------------------------------------------------------------------------- 1 | ISC License 2 | 3 | Copyright (c) 2012-2016 Dave Collins 4 | 5 | Permission to use, copy, modify, and/or distribute this software for any 6 | purpose with or without fee is hereby granted, provided that the above 7 | copyright notice and this permission notice appear in all copies. 8 | 9 | THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 10 | WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 11 | MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 12 | ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 13 | WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 14 | ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 15 | OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 16 | -------------------------------------------------------------------------------- /vendor/github.com/deckarep/golang-set/v2/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | 10 | # Architecture specific extensions/prefixes 11 | *.[568vq] 12 | [568vq].out 13 | 14 | *.cgo1.go 15 | *.cgo2.c 16 | _cgo_defun.c 17 | _cgo_gotypes.go 18 | _cgo_export.* 19 | 20 | _testmain.go 21 | 22 | *.exe 23 | -------------------------------------------------------------------------------- /vendor/github.com/deckarep/golang-set/v2/new_improved.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/deckarep/golang-set/v2/new_improved.jpeg -------------------------------------------------------------------------------- /vendor/github.com/dustin/go-humanize/.travis.yml: -------------------------------------------------------------------------------- 1 | sudo: false 2 | language: go 3 | go_import_path: github.com/dustin/go-humanize 4 | go: 5 | - 1.13.x 6 | - 1.14.x 7 | - 1.15.x 8 | - 1.16.x 9 | - stable 10 | - master 11 | matrix: 12 | allow_failures: 13 | - go: master 14 | fast_finish: true 15 | install: 16 | - # Do nothing. This is needed to prevent default install action "go get -t -v ./..." from happening here (we want it to happen inside script step). 17 | script: 18 | - diff -u <(echo -n) <(gofmt -d -s .) 19 | - go vet . 20 | - go install -v -race ./... 21 | - go test -v -race ./... 22 | -------------------------------------------------------------------------------- /vendor/github.com/dustin/go-humanize/big.go: -------------------------------------------------------------------------------- 1 | package humanize 2 | 3 | import ( 4 | "math/big" 5 | ) 6 | 7 | // order of magnitude (to a max order) 8 | func oomm(n, b *big.Int, maxmag int) (float64, int) { 9 | mag := 0 10 | m := &big.Int{} 11 | for n.Cmp(b) >= 0 { 12 | n.DivMod(n, b, m) 13 | mag++ 14 | if mag == maxmag && maxmag >= 0 { 15 | break 16 | } 17 | } 18 | return float64(n.Int64()) + (float64(m.Int64()) / float64(b.Int64())), mag 19 | } 20 | 21 | // total order of magnitude 22 | // (same as above, but with no upper limit) 23 | func oom(n, b *big.Int) (float64, int) { 24 | mag := 0 25 | m := &big.Int{} 26 | for n.Cmp(b) >= 0 { 27 | n.DivMod(n, b, m) 28 | mag++ 29 | } 30 | return float64(n.Int64()) + (float64(m.Int64()) / float64(b.Int64())), mag 31 | } 32 | -------------------------------------------------------------------------------- /vendor/github.com/dustin/go-humanize/humanize.go: -------------------------------------------------------------------------------- 1 | /* 2 | Package humanize converts boring ugly numbers to human-friendly strings and back. 3 | 4 | Durations can be turned into strings such as "3 days ago", numbers 5 | representing sizes like 82854982 into useful strings like, "83 MB" or 6 | "79 MiB" (whichever you prefer). 7 | */ 8 | package humanize 9 | -------------------------------------------------------------------------------- /vendor/github.com/dustin/go-humanize/ordinals.go: -------------------------------------------------------------------------------- 1 | package humanize 2 | 3 | import "strconv" 4 | 5 | // Ordinal gives you the input number in a rank/ordinal format. 6 | // 7 | // Ordinal(3) -> 3rd 8 | func Ordinal(x int) string { 9 | suffix := "th" 10 | switch x % 10 { 11 | case 1: 12 | if x%100 != 11 { 13 | suffix = "st" 14 | } 15 | case 2: 16 | if x%100 != 12 { 17 | suffix = "nd" 18 | } 19 | case 3: 20 | if x%100 != 13 { 21 | suffix = "rd" 22 | } 23 | } 24 | return strconv.Itoa(x) + suffix 25 | } 26 | -------------------------------------------------------------------------------- /vendor/github.com/gin-contrib/sse/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | sudo: false 3 | go: 4 | - 1.8.x 5 | - 1.9.x 6 | - 1.10.x 7 | - 1.11.x 8 | - 1.12.x 9 | - master 10 | 11 | git: 12 | depth: 10 13 | 14 | matrix: 15 | fast_finish: true 16 | include: 17 | - go: 1.11.x 18 | env: GO111MODULE=on 19 | - go: 1.12.x 20 | env: GO111MODULE=on 21 | 22 | script: 23 | - go test -v -covermode=count -coverprofile=coverage.out 24 | 25 | after_success: 26 | - bash <(curl -s https://codecov.io/bash) 27 | -------------------------------------------------------------------------------- /vendor/github.com/gin-contrib/sse/writer.go: -------------------------------------------------------------------------------- 1 | package sse 2 | 3 | import "io" 4 | 5 | type stringWriter interface { 6 | io.Writer 7 | WriteString(string) (int, error) 8 | } 9 | 10 | type stringWrapper struct { 11 | io.Writer 12 | } 13 | 14 | func (w stringWrapper) WriteString(str string) (int, error) { 15 | return w.Writer.Write([]byte(str)) 16 | } 17 | 18 | func checkWriter(writer io.Writer) stringWriter { 19 | if w, ok := writer.(stringWriter); ok { 20 | return w 21 | } else { 22 | return stringWrapper{writer} 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/.gitignore: -------------------------------------------------------------------------------- 1 | vendor/* 2 | !vendor/vendor.json 3 | coverage.out 4 | count.out 5 | test 6 | profile.out 7 | tmp.out 8 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | ## Contributing 2 | 3 | - With issues: 4 | - Use the search tool before opening a new issue. 5 | - Please provide source code and commit sha if you found a bug. 6 | - Review existing issues and provide feedback or react to them. 7 | 8 | - With pull requests: 9 | - Open your pull request against `master` 10 | - Your pull request should have no more than two commits, if not you should squash them. 11 | - It should pass all tests in the available continuous integration systems such as GitHub Actions. 12 | - You should add/modify tests to cover your proposed code changes. 13 | - If your pull request contains a new feature, please document it on the README. 14 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/any.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 Gin Core Team. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !go1.18 6 | // +build !go1.18 7 | 8 | package gin 9 | 10 | type any = interface{} 11 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/binding/any.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 Gin Core Team. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !go1.18 6 | // +build !go1.18 7 | 8 | package binding 9 | 10 | type any = interface{} 11 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/binding/query.go: -------------------------------------------------------------------------------- 1 | // Copyright 2017 Manu Martinez-Almeida. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | package binding 6 | 7 | import "net/http" 8 | 9 | type queryBinding struct{} 10 | 11 | func (queryBinding) Name() string { 12 | return "query" 13 | } 14 | 15 | func (queryBinding) Bind(req *http.Request, obj any) error { 16 | values := req.URL.Query() 17 | if err := mapForm(obj, values); err != nil { 18 | return err 19 | } 20 | return validate(obj) 21 | } 22 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/binding/uri.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 Gin Core Team. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | package binding 6 | 7 | type uriBinding struct{} 8 | 9 | func (uriBinding) Name() string { 10 | return "uri" 11 | } 12 | 13 | func (uriBinding) BindUri(m map[string][]string, obj any) error { 14 | if err := mapURI(obj, m); err != nil { 15 | return err 16 | } 17 | return validate(obj) 18 | } 19 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/binding/xml.go: -------------------------------------------------------------------------------- 1 | // Copyright 2014 Manu Martinez-Almeida. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | package binding 6 | 7 | import ( 8 | "bytes" 9 | "encoding/xml" 10 | "io" 11 | "net/http" 12 | ) 13 | 14 | type xmlBinding struct{} 15 | 16 | func (xmlBinding) Name() string { 17 | return "xml" 18 | } 19 | 20 | func (xmlBinding) Bind(req *http.Request, obj any) error { 21 | return decodeXML(req.Body, obj) 22 | } 23 | 24 | func (xmlBinding) BindBody(body []byte, obj any) error { 25 | return decodeXML(bytes.NewReader(body), obj) 26 | } 27 | func decodeXML(r io.Reader, obj any) error { 28 | decoder := xml.NewDecoder(r) 29 | if err := decoder.Decode(obj); err != nil { 30 | return err 31 | } 32 | return validate(obj) 33 | } 34 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/binding/yaml.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 Gin Core Team. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | package binding 6 | 7 | import ( 8 | "bytes" 9 | "io" 10 | "net/http" 11 | 12 | "gopkg.in/yaml.v2" 13 | ) 14 | 15 | type yamlBinding struct{} 16 | 17 | func (yamlBinding) Name() string { 18 | return "yaml" 19 | } 20 | 21 | func (yamlBinding) Bind(req *http.Request, obj any) error { 22 | return decodeYAML(req.Body, obj) 23 | } 24 | 25 | func (yamlBinding) BindBody(body []byte, obj any) error { 26 | return decodeYAML(bytes.NewReader(body), obj) 27 | } 28 | 29 | func decodeYAML(r io.Reader, obj any) error { 30 | decoder := yaml.NewDecoder(r) 31 | if err := decoder.Decode(obj); err != nil { 32 | return err 33 | } 34 | return validate(obj) 35 | } 36 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/codecov.yml: -------------------------------------------------------------------------------- 1 | coverage: 2 | notify: 3 | gitter: 4 | default: 5 | url: https://webhooks.gitter.im/e/d90dcdeeab2f1e357165 6 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/context_appengine.go: -------------------------------------------------------------------------------- 1 | // Copyright 2017 Manu Martinez-Almeida. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build appengine 6 | // +build appengine 7 | 8 | package gin 9 | 10 | func init() { 11 | defaultPlatform = PlatformGoogleAppEngine 12 | } 13 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/deprecated.go: -------------------------------------------------------------------------------- 1 | // Copyright 2014 Manu Martinez-Almeida. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | package gin 6 | 7 | import ( 8 | "log" 9 | 10 | "github.com/gin-gonic/gin/binding" 11 | ) 12 | 13 | // BindWith binds the passed struct pointer using the specified binding engine. 14 | // See the binding package. 15 | func (c *Context) BindWith(obj any, b binding.Binding) error { 16 | log.Println(`BindWith(\"interface{}, binding.Binding\") error is going to 17 | be deprecated, please check issue #662 and either use MustBindWith() if you 18 | want HTTP 400 to be automatically returned if any error occur, or use 19 | ShouldBindWith() if you need to manage the error.`) 20 | return c.MustBindWith(obj, b) 21 | } 22 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/doc.go: -------------------------------------------------------------------------------- 1 | /* 2 | Package gin implements a HTTP web framework called gin. 3 | 4 | See https://gin-gonic.com/ for more information about gin. 5 | */ 6 | package gin // import "github.com/gin-gonic/gin" 7 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/internal/bytesconv/bytesconv.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 Gin Core Team. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | package bytesconv 6 | 7 | import ( 8 | "unsafe" 9 | ) 10 | 11 | // StringToBytes converts string to byte slice without a memory allocation. 12 | func StringToBytes(s string) []byte { 13 | return *(*[]byte)(unsafe.Pointer( 14 | &struct { 15 | string 16 | Cap int 17 | }{s, len(s)}, 18 | )) 19 | } 20 | 21 | // BytesToString converts byte slice to string without a memory allocation. 22 | func BytesToString(b []byte) string { 23 | return *(*string)(unsafe.Pointer(&b)) 24 | } 25 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/internal/json/go_json.go: -------------------------------------------------------------------------------- 1 | // Copyright 2017 Bo-Yi Wu. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build go_json 6 | // +build go_json 7 | 8 | package json 9 | 10 | import json "github.com/goccy/go-json" 11 | 12 | var ( 13 | // Marshal is exported by gin/json package. 14 | Marshal = json.Marshal 15 | // Unmarshal is exported by gin/json package. 16 | Unmarshal = json.Unmarshal 17 | // MarshalIndent is exported by gin/json package. 18 | MarshalIndent = json.MarshalIndent 19 | // NewDecoder is exported by gin/json package. 20 | NewDecoder = json.NewDecoder 21 | // NewEncoder is exported by gin/json package. 22 | NewEncoder = json.NewEncoder 23 | ) 24 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/internal/json/json.go: -------------------------------------------------------------------------------- 1 | // Copyright 2017 Bo-Yi Wu. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !jsoniter && !go_json 6 | // +build !jsoniter,!go_json 7 | 8 | package json 9 | 10 | import "encoding/json" 11 | 12 | var ( 13 | // Marshal is exported by gin/json package. 14 | Marshal = json.Marshal 15 | // Unmarshal is exported by gin/json package. 16 | Unmarshal = json.Unmarshal 17 | // MarshalIndent is exported by gin/json package. 18 | MarshalIndent = json.MarshalIndent 19 | // NewDecoder is exported by gin/json package. 20 | NewDecoder = json.NewDecoder 21 | // NewEncoder is exported by gin/json package. 22 | NewEncoder = json.NewEncoder 23 | ) 24 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/internal/json/jsoniter.go: -------------------------------------------------------------------------------- 1 | // Copyright 2017 Bo-Yi Wu. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build jsoniter 6 | // +build jsoniter 7 | 8 | package json 9 | 10 | import jsoniter "github.com/json-iterator/go" 11 | 12 | var ( 13 | json = jsoniter.ConfigCompatibleWithStandardLibrary 14 | // Marshal is exported by gin/json package. 15 | Marshal = json.Marshal 16 | // Unmarshal is exported by gin/json package. 17 | Unmarshal = json.Unmarshal 18 | // MarshalIndent is exported by gin/json package. 19 | MarshalIndent = json.MarshalIndent 20 | // NewDecoder is exported by gin/json package. 21 | NewDecoder = json.NewDecoder 22 | // NewEncoder is exported by gin/json package. 23 | NewEncoder = json.NewEncoder 24 | ) 25 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/render/any.go: -------------------------------------------------------------------------------- 1 | // Copyright 2021 Gin Core Team. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !go1.18 6 | // +build !go1.18 7 | 8 | package render 9 | 10 | type any = interface{} 11 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/render/data.go: -------------------------------------------------------------------------------- 1 | // Copyright 2014 Manu Martinez-Almeida. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | package render 6 | 7 | import "net/http" 8 | 9 | // Data contains ContentType and bytes data. 10 | type Data struct { 11 | ContentType string 12 | Data []byte 13 | } 14 | 15 | // Render (Data) writes data with custom ContentType. 16 | func (r Data) Render(w http.ResponseWriter) (err error) { 17 | r.WriteContentType(w) 18 | _, err = w.Write(r.Data) 19 | return 20 | } 21 | 22 | // WriteContentType (Data) writes custom ContentType. 23 | func (r Data) WriteContentType(w http.ResponseWriter) { 24 | writeContentType(w, []string{r.ContentType}) 25 | } 26 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/test_helpers.go: -------------------------------------------------------------------------------- 1 | // Copyright 2017 Manu Martinez-Almeida. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | package gin 6 | 7 | import "net/http" 8 | 9 | // CreateTestContext returns a fresh engine and context for testing purposes 10 | func CreateTestContext(w http.ResponseWriter) (c *Context, r *Engine) { 11 | r = New() 12 | c = r.allocateContext() 13 | c.reset() 14 | c.writermem.reset(w) 15 | return 16 | } 17 | -------------------------------------------------------------------------------- /vendor/github.com/gin-gonic/gin/version.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 Gin Core Team. All rights reserved. 2 | // Use of this source code is governed by a MIT style 3 | // license that can be found in the LICENSE file. 4 | 5 | package gin 6 | 7 | // Version is the current gin framework's version. 8 | const Version = "v1.8.1" 9 | -------------------------------------------------------------------------------- /vendor/github.com/go-playground/locales/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | 10 | # Architecture specific extensions/prefixes 11 | *.[568vq] 12 | [568vq].out 13 | 14 | *.cgo1.go 15 | *.cgo2.c 16 | _cgo_defun.c 17 | _cgo_gotypes.go 18 | _cgo_export.* 19 | 20 | _testmain.go 21 | 22 | *.exe 23 | *.test 24 | *.prof 25 | -------------------------------------------------------------------------------- /vendor/github.com/go-playground/locales/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | go: 3 | - 1.13.1 4 | - tip 5 | matrix: 6 | allow_failures: 7 | - go: tip 8 | 9 | notifications: 10 | email: 11 | recipients: dean.karn@gmail.com 12 | on_success: change 13 | on_failure: always 14 | 15 | before_install: 16 | - go install github.com/mattn/goveralls 17 | 18 | # Only clone the most recent commit. 19 | git: 20 | depth: 1 21 | 22 | script: 23 | - go test -v -race -covermode=atomic -coverprofile=coverage.coverprofile ./... 24 | 25 | after_success: | 26 | goveralls -coverprofile=coverage.coverprofile -service travis-ci -repotoken $COVERALLS_TOKEN -------------------------------------------------------------------------------- /vendor/github.com/go-playground/locales/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/go-playground/locales/logo.png -------------------------------------------------------------------------------- /vendor/github.com/go-playground/universal-translator/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | 10 | # Architecture specific extensions/prefixes 11 | *.[568vq] 12 | [568vq].out 13 | 14 | *.cgo1.go 15 | *.cgo2.c 16 | _cgo_defun.c 17 | _cgo_gotypes.go 18 | _cgo_export.* 19 | 20 | _testmain.go 21 | 22 | *.exe 23 | *.test 24 | *.prof 25 | *.coverprofile -------------------------------------------------------------------------------- /vendor/github.com/go-playground/universal-translator/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | go: 3 | - 1.13.4 4 | - tip 5 | matrix: 6 | allow_failures: 7 | - go: tip 8 | 9 | notifications: 10 | email: 11 | recipients: dean.karn@gmail.com 12 | on_success: change 13 | on_failure: always 14 | 15 | before_install: 16 | - go install github.com/mattn/goveralls 17 | 18 | # Only clone the most recent commit. 19 | git: 20 | depth: 1 21 | 22 | script: 23 | - go test -v -race -covermode=atomic -coverprofile=coverage.coverprofile ./... 24 | 25 | after_success: | 26 | [ $TRAVIS_GO_VERSION = 1.13.4 ] && 27 | goveralls -coverprofile=coverage.coverprofile -service travis-ci -repotoken $COVERALLS_TOKEN -------------------------------------------------------------------------------- /vendor/github.com/go-playground/universal-translator/Makefile: -------------------------------------------------------------------------------- 1 | GOCMD=GO111MODULE=on go 2 | 3 | linters-install: 4 | @golangci-lint --version >/dev/null 2>&1 || { \ 5 | echo "installing linting tools..."; \ 6 | curl -sfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh| sh -s v1.41.1; \ 7 | } 8 | 9 | lint: linters-install 10 | golangci-lint run 11 | 12 | test: 13 | $(GOCMD) test -cover -race ./... 14 | 15 | bench: 16 | $(GOCMD) test -bench=. -benchmem ./... 17 | 18 | .PHONY: test lint linters-install -------------------------------------------------------------------------------- /vendor/github.com/go-playground/universal-translator/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/go-playground/universal-translator/logo.png -------------------------------------------------------------------------------- /vendor/github.com/go-playground/validator/v10/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | bin 10 | 11 | # Architecture specific extensions/prefixes 12 | *.[568vq] 13 | [568vq].out 14 | 15 | *.cgo1.go 16 | *.cgo2.c 17 | _cgo_defun.c 18 | _cgo_gotypes.go 19 | _cgo_export.* 20 | 21 | _testmain.go 22 | 23 | *.exe 24 | *.test 25 | *.prof 26 | *.test 27 | *.out 28 | *.txt 29 | cover.html 30 | README.html 31 | -------------------------------------------------------------------------------- /vendor/github.com/go-playground/validator/v10/MAINTAINERS.md: -------------------------------------------------------------------------------- 1 | ## Maintainers Guide 2 | 3 | ### Semantic Versioning 4 | Semantic versioning as defined [here](https://semver.org) must be strictly adhered to. 5 | 6 | ### External Dependencies 7 | Any new external dependencies MUST: 8 | - Have a compatible LICENSE present. 9 | - Be actively maintained. 10 | - Be approved by @go-playground/admins 11 | 12 | ### PR Merge Requirements 13 | - Up-to-date branch. 14 | - Passing tests and linting. 15 | - CODEOWNERS approval. 16 | - Tests that cover both the Happy and Unhappy paths. -------------------------------------------------------------------------------- /vendor/github.com/go-playground/validator/v10/Makefile: -------------------------------------------------------------------------------- 1 | GOCMD=GO111MODULE=on go 2 | 3 | linters-install: 4 | @golangci-lint --version >/dev/null 2>&1 || { \ 5 | echo "installing linting tools..."; \ 6 | curl -sfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh| sh -s v1.41.1; \ 7 | } 8 | 9 | lint: linters-install 10 | golangci-lint run 11 | 12 | test: 13 | $(GOCMD) test -cover -race ./... 14 | 15 | bench: 16 | $(GOCMD) test -bench=. -benchmem ./... 17 | 18 | .PHONY: test lint linters-install -------------------------------------------------------------------------------- /vendor/github.com/go-playground/validator/v10/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/go-playground/validator/v10/logo.png -------------------------------------------------------------------------------- /vendor/github.com/go-playground/validator/v10/translations.go: -------------------------------------------------------------------------------- 1 | package validator 2 | 3 | import ut "github.com/go-playground/universal-translator" 4 | 5 | // TranslationFunc is the function type used to register or override 6 | // custom translations 7 | type TranslationFunc func(ut ut.Translator, fe FieldError) string 8 | 9 | // RegisterTranslationsFunc allows for registering of translations 10 | // for a 'ut.Translator' for use within the 'TranslationFunc' 11 | type RegisterTranslationsFunc func(ut ut.Translator) error 12 | -------------------------------------------------------------------------------- /vendor/github.com/goccy/go-json/.codecov.yml: -------------------------------------------------------------------------------- 1 | codecov: 2 | require_ci_to_pass: yes 3 | 4 | coverage: 5 | precision: 2 6 | round: down 7 | range: "70...100" 8 | 9 | status: 10 | project: 11 | default: 12 | target: 70% 13 | threshold: 2% 14 | patch: off 15 | changes: no 16 | 17 | parsers: 18 | gcov: 19 | branch_detection: 20 | conditional: yes 21 | loop: yes 22 | method: no 23 | macro: no 24 | 25 | comment: 26 | layout: "header,diff" 27 | behavior: default 28 | require_changes: no 29 | 30 | ignore: 31 | - internal/encoder/vm_color 32 | - internal/encoder/vm_color_indent 33 | -------------------------------------------------------------------------------- /vendor/github.com/goccy/go-json/.gitignore: -------------------------------------------------------------------------------- 1 | cover.html 2 | cover.out 3 | -------------------------------------------------------------------------------- /vendor/github.com/goccy/go-json/docker-compose.yml: -------------------------------------------------------------------------------- 1 | version: '2' 2 | services: 3 | go-json: 4 | image: golang:1.18 5 | volumes: 6 | - '.:/go/src/go-json' 7 | deploy: 8 | resources: 9 | limits: 10 | memory: 620M 11 | working_dir: /go/src/go-json 12 | command: | 13 | sh -c "go test -c . && ls go-json.test" 14 | -------------------------------------------------------------------------------- /vendor/github.com/goccy/go-json/internal/decoder/compile_norace.go: -------------------------------------------------------------------------------- 1 | //go:build !race 2 | // +build !race 3 | 4 | package decoder 5 | 6 | import ( 7 | "unsafe" 8 | 9 | "github.com/goccy/go-json/internal/runtime" 10 | ) 11 | 12 | func CompileToGetDecoder(typ *runtime.Type) (Decoder, error) { 13 | typeptr := uintptr(unsafe.Pointer(typ)) 14 | if typeptr > typeAddr.MaxTypeAddr { 15 | return compileToGetDecoderSlowPath(typeptr, typ) 16 | } 17 | 18 | index := (typeptr - typeAddr.BaseTypeAddr) >> typeAddr.AddrShift 19 | if dec := cachedDecoder[index]; dec != nil { 20 | return dec, nil 21 | } 22 | 23 | dec, err := compileHead(typ, map[uintptr]Decoder{}) 24 | if err != nil { 25 | return nil, err 26 | } 27 | cachedDecoder[index] = dec 28 | return dec, nil 29 | } 30 | -------------------------------------------------------------------------------- /vendor/github.com/goccy/go-json/internal/decoder/option.go: -------------------------------------------------------------------------------- 1 | package decoder 2 | 3 | import "context" 4 | 5 | type OptionFlags uint8 6 | 7 | const ( 8 | FirstWinOption OptionFlags = 1 << iota 9 | ContextOption 10 | ) 11 | 12 | type Option struct { 13 | Flags OptionFlags 14 | Context context.Context 15 | } 16 | -------------------------------------------------------------------------------- /vendor/github.com/goccy/go-json/internal/decoder/type.go: -------------------------------------------------------------------------------- 1 | package decoder 2 | 3 | import ( 4 | "context" 5 | "encoding" 6 | "encoding/json" 7 | "reflect" 8 | "unsafe" 9 | ) 10 | 11 | type Decoder interface { 12 | Decode(*RuntimeContext, int64, int64, unsafe.Pointer) (int64, error) 13 | DecodeStream(*Stream, int64, unsafe.Pointer) error 14 | } 15 | 16 | const ( 17 | nul = '\000' 18 | maxDecodeNestingDepth = 10000 19 | ) 20 | 21 | type unmarshalerContext interface { 22 | UnmarshalJSON(context.Context, []byte) error 23 | } 24 | 25 | var ( 26 | unmarshalJSONType = reflect.TypeOf((*json.Unmarshaler)(nil)).Elem() 27 | unmarshalJSONContextType = reflect.TypeOf((*unmarshalerContext)(nil)).Elem() 28 | unmarshalTextType = reflect.TypeOf((*encoding.TextUnmarshaler)(nil)).Elem() 29 | ) 30 | -------------------------------------------------------------------------------- /vendor/github.com/goccy/go-json/internal/encoder/map112.go: -------------------------------------------------------------------------------- 1 | //go:build !go1.13 2 | // +build !go1.13 3 | 4 | package encoder 5 | 6 | import "unsafe" 7 | 8 | //go:linkname MapIterValue reflect.mapitervalue 9 | func MapIterValue(it *mapIter) unsafe.Pointer 10 | -------------------------------------------------------------------------------- /vendor/github.com/goccy/go-json/internal/encoder/map113.go: -------------------------------------------------------------------------------- 1 | //go:build go1.13 2 | // +build go1.13 3 | 4 | package encoder 5 | 6 | import "unsafe" 7 | 8 | //go:linkname MapIterValue reflect.mapiterelem 9 | func MapIterValue(it *mapIter) unsafe.Pointer 10 | -------------------------------------------------------------------------------- /vendor/github.com/goccy/go-json/internal/encoder/vm/hack.go: -------------------------------------------------------------------------------- 1 | package vm 2 | 3 | import ( 4 | // HACK: compile order 5 | // `vm`, `vm_indent`, `vm_color`, `vm_color_indent` packages uses a lot of memory to compile, 6 | // so forcibly make dependencies and avoid compiling in concurrent. 7 | // dependency order: vm => vm_indent => vm_color => vm_color_indent 8 | _ "github.com/goccy/go-json/internal/encoder/vm_indent" 9 | ) 10 | -------------------------------------------------------------------------------- /vendor/github.com/goccy/go-json/internal/encoder/vm_color/hack.go: -------------------------------------------------------------------------------- 1 | package vm_color 2 | 3 | import ( 4 | // HACK: compile order 5 | // `vm`, `vm_indent`, `vm_color`, `vm_color_indent` packages uses a lot of memory to compile, 6 | // so forcibly make dependencies and avoid compiling in concurrent. 7 | // dependency order: vm => vm_indent => vm_color => vm_color_indent 8 | _ "github.com/goccy/go-json/internal/encoder/vm_color_indent" 9 | ) 10 | -------------------------------------------------------------------------------- /vendor/github.com/goccy/go-json/internal/encoder/vm_indent/hack.go: -------------------------------------------------------------------------------- 1 | package vm_indent 2 | 3 | import ( 4 | // HACK: compile order 5 | // `vm`, `vm_indent`, `vm_color`, `vm_color_indent` packages uses a lot of memory to compile, 6 | // so forcibly make dependencies and avoid compiling in concurrent. 7 | // dependency order: vm => vm_indent => vm_color => vm_color_indent 8 | _ "github.com/goccy/go-json/internal/encoder/vm_color" 9 | ) 10 | -------------------------------------------------------------------------------- /vendor/github.com/golang/snappy/.gitignore: -------------------------------------------------------------------------------- 1 | cmd/snappytool/snappytool 2 | testdata/bench 3 | 4 | # These explicitly listed benchmark data files are for an obsolete version of 5 | # snappy_test.go. 6 | testdata/alice29.txt 7 | testdata/asyoulik.txt 8 | testdata/fireworks.jpeg 9 | testdata/geo.protodata 10 | testdata/html 11 | testdata/html_x_4 12 | testdata/kppkn.gtb 13 | testdata/lcet10.txt 14 | testdata/paper-100k.pdf 15 | testdata/plrabn12.txt 16 | testdata/urls.10K 17 | -------------------------------------------------------------------------------- /vendor/github.com/golang/snappy/AUTHORS: -------------------------------------------------------------------------------- 1 | # This is the official list of Snappy-Go authors for copyright purposes. 2 | # This file is distinct from the CONTRIBUTORS files. 3 | # See the latter for an explanation. 4 | 5 | # Names should be added to this file as 6 | # Name or Organization 7 | # The email address is not required for organizations. 8 | 9 | # Please keep the list sorted. 10 | 11 | Amazon.com, Inc 12 | Damian Gryski 13 | Eric Buth 14 | Google Inc. 15 | Jan Mercl <0xjnml@gmail.com> 16 | Klaus Post 17 | Rodolfo Carvalho 18 | Sebastien Binet 19 | -------------------------------------------------------------------------------- /vendor/github.com/golang/snappy/decode_asm.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Snappy-Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build !appengine 6 | // +build gc 7 | // +build !noasm 8 | // +build amd64 arm64 9 | 10 | package snappy 11 | 12 | // decode has the same semantics as in decode_other.go. 13 | // 14 | //go:noescape 15 | func decode(dst, src []byte) int 16 | -------------------------------------------------------------------------------- /vendor/github.com/google/uuid/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | 3 | go: 4 | - 1.4.3 5 | - 1.5.3 6 | - tip 7 | 8 | script: 9 | - go test -v ./... 10 | -------------------------------------------------------------------------------- /vendor/github.com/google/uuid/CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # How to contribute 2 | 3 | We definitely welcome patches and contribution to this project! 4 | 5 | ### Legal requirements 6 | 7 | In order to protect both you and ourselves, you will need to sign the 8 | [Contributor License Agreement](https://cla.developers.google.com/clas). 9 | 10 | You may have already signed it for other Google projects. 11 | -------------------------------------------------------------------------------- /vendor/github.com/google/uuid/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | Paul Borman 2 | bmatsuo 3 | shawnps 4 | theory 5 | jboverfelt 6 | dsymonds 7 | cd1 8 | wallclockbuilder 9 | dansouza 10 | -------------------------------------------------------------------------------- /vendor/github.com/google/uuid/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 Google Inc. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Package uuid generates and inspects UUIDs. 6 | // 7 | // UUIDs are based on RFC 4122 and DCE 1.1: Authentication and Security 8 | // Services. 9 | // 10 | // A UUID is a 16 byte (128 bit) array. UUIDs may be used as keys to 11 | // maps or compared directly. 12 | package uuid 13 | -------------------------------------------------------------------------------- /vendor/github.com/google/uuid/node_js.go: -------------------------------------------------------------------------------- 1 | // Copyright 2017 Google Inc. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // +build js 6 | 7 | package uuid 8 | 9 | // getHardwareInterface returns nil values for the JS version of the code. 10 | // This remvoves the "net" dependency, because it is not used in the browser. 11 | // Using the "net" library inflates the size of the transpiled JS code by 673k bytes. 12 | func getHardwareInterface(name string) (string, []byte) { return "", nil } 13 | -------------------------------------------------------------------------------- /vendor/github.com/huandu/go-clone/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | 10 | # Architecture specific extensions/prefixes 11 | *.[568vq] 12 | [568vq].out 13 | 14 | *.cgo1.go 15 | *.cgo2.c 16 | _cgo_defun.c 17 | _cgo_gotypes.go 18 | _cgo_export.* 19 | 20 | _testmain.go 21 | 22 | *.exe 23 | *.test 24 | *.prof 25 | 26 | # Intellij 27 | *.iml 28 | .idea/ 29 | 30 | # VS Code 31 | debug 32 | debug_test 33 | .vscode/ 34 | 35 | # Mac 36 | .DS_Store 37 | 38 | # go workspace 39 | go.work 40 | go.work.sum 41 | -------------------------------------------------------------------------------- /vendor/github.com/huandu/go-clone/arena.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 Huan Du. All rights reserved. 2 | // Licensed under the MIT license that can be found in the LICENSE file. 3 | 4 | //go:build !(go1.20 && goexperiment.arenas) 5 | // +build !go1.20 !goexperiment.arenas 6 | 7 | package clone 8 | 9 | const arenaIsEnabled = false 10 | -------------------------------------------------------------------------------- /vendor/github.com/huandu/go-clone/arena_go120.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 Huan Du. All rights reserved. 2 | // Licensed under the MIT license that can be found in the LICENSE file. 3 | 4 | //go:build go1.20 && goexperiment.arenas 5 | // +build go1.20,goexperiment.arenas 6 | 7 | package clone 8 | 9 | const arenaIsEnabled = true 10 | -------------------------------------------------------------------------------- /vendor/github.com/huandu/go-clone/cloner.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 Huan Du. All rights reserved. 2 | // Licensed under the MIT license that can be found in the LICENSE file. 3 | 4 | package clone 5 | 6 | // Cloner implements clone API with given allocator. 7 | type Cloner struct { 8 | allocator *Allocator 9 | } 10 | 11 | // MakeCloner creates a cloner with given allocator. 12 | func MakeCloner(allocator *Allocator) Cloner { 13 | return Cloner{ 14 | allocator: allocator, 15 | } 16 | } 17 | 18 | // Clone clones v with given allocator. 19 | func (c Cloner) Clone(v interface{}) interface{} { 20 | return clone(c.allocator, v) 21 | } 22 | 23 | // CloneSlowly clones v with given allocator. 24 | // It can clone v with cycle pointer. 25 | func (c Cloner) CloneSlowly(v interface{}) interface{} { 26 | return cloneSlowly(c.allocator, v) 27 | } 28 | -------------------------------------------------------------------------------- /vendor/github.com/huandu/go-clone/generic/README.md: -------------------------------------------------------------------------------- 1 | # Generic `go-clone` API 2 | 3 | [![Go](https://github.com/huandu/go-clone/workflows/Go/badge.svg)](https://github.com/huandu/go-clone/actions) 4 | [![Go Doc](https://godoc.org/github.com/huandu/go-clone/generic?status.svg)](https://pkg.go.dev/github.com/huandu/go-clone/generic) 5 | 6 | This package is a set of generic API for `go-clone`. Almost all methods are simple proxies with a few exceptions. It requires `go1.18` or later to build this package. 7 | 8 | Please read document in [the main project](../README.md) for more information. 9 | -------------------------------------------------------------------------------- /vendor/github.com/huandu/go-clone/headers.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 Huan Du. All rights reserved. 2 | // Licensed under the MIT license that can be found in the LICENSE file. 3 | 4 | package clone 5 | 6 | import "reflect" 7 | 8 | // As golint reports warning on possible misuse of these headers, 9 | // avoid to use these header types directly to silience golint. 10 | 11 | type sliceHeader reflect.SliceHeader 12 | type stringHeader reflect.StringHeader 13 | -------------------------------------------------------------------------------- /vendor/github.com/huandu/go-clone/mapiter.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 Huan Du. All rights reserved. 2 | // Licensed under the MIT license that can be found in the LICENSE file. 3 | 4 | // +build !go1.12 5 | 6 | package clone 7 | 8 | import ( 9 | "reflect" 10 | ) 11 | 12 | type iter struct { 13 | m reflect.Value 14 | k reflect.Value 15 | keys []reflect.Value 16 | } 17 | 18 | func mapIter(m reflect.Value) *iter { 19 | return &iter{ 20 | m: m, 21 | keys: m.MapKeys(), 22 | } 23 | } 24 | 25 | func (it *iter) Next() bool { 26 | if len(it.keys) == 0 { 27 | return false 28 | } 29 | 30 | it.k = it.keys[0] 31 | it.keys = it.keys[1:] 32 | return true 33 | } 34 | 35 | func (it *iter) Key() reflect.Value { 36 | return it.k 37 | } 38 | 39 | func (it *iter) Value() reflect.Value { 40 | return it.m.MapIndex(it.k) 41 | } 42 | -------------------------------------------------------------------------------- /vendor/github.com/huandu/go-clone/mapiter_go112.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 Huan Du. All rights reserved. 2 | // Licensed under the MIT license that can be found in the LICENSE file. 3 | 4 | // +build go1.12 5 | 6 | package clone 7 | 8 | import ( 9 | "reflect" 10 | ) 11 | 12 | func mapIter(m reflect.Value) *reflect.MapIter { 13 | return m.MapRange() 14 | } 15 | -------------------------------------------------------------------------------- /vendor/github.com/huandu/go-clone/memory.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 Huan Du. All rights reserved. 2 | // Licensed under the MIT license that can be found in the LICENSE file. 3 | 4 | package clone 5 | 6 | // maxByteSize is a large enough value to cheat Go compiler 7 | // when converting unsafe address to []byte. 8 | // It's not actually used in runtime. 9 | // 10 | // The value 2^30 is the max value AFAIK to make Go compiler happy on all archs. 11 | const maxByteSize = 1 << 30 12 | -------------------------------------------------------------------------------- /vendor/github.com/json-iterator/go/.codecov.yml: -------------------------------------------------------------------------------- 1 | ignore: 2 | - "output_tests/.*" 3 | 4 | -------------------------------------------------------------------------------- /vendor/github.com/json-iterator/go/.gitignore: -------------------------------------------------------------------------------- 1 | /vendor 2 | /bug_test.go 3 | /coverage.txt 4 | /.idea 5 | -------------------------------------------------------------------------------- /vendor/github.com/json-iterator/go/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | 3 | go: 4 | - 1.8.x 5 | - 1.x 6 | 7 | before_install: 8 | - go get -t -v ./... 9 | 10 | script: 11 | - ./test.sh 12 | 13 | after_success: 14 | - bash <(curl -s https://codecov.io/bash) 15 | -------------------------------------------------------------------------------- /vendor/github.com/json-iterator/go/Gopkg.lock: -------------------------------------------------------------------------------- 1 | # This file is autogenerated, do not edit; changes may be undone by the next 'dep ensure'. 2 | 3 | 4 | [[projects]] 5 | name = "github.com/modern-go/concurrent" 6 | packages = ["."] 7 | revision = "e0a39a4cb4216ea8db28e22a69f4ec25610d513a" 8 | version = "1.0.0" 9 | 10 | [[projects]] 11 | name = "github.com/modern-go/reflect2" 12 | packages = ["."] 13 | revision = "4b7aa43c6742a2c18fdef89dd197aaae7dac7ccd" 14 | version = "1.0.1" 15 | 16 | [solve-meta] 17 | analyzer-name = "dep" 18 | analyzer-version = 1 19 | inputs-digest = "ea54a775e5a354cb015502d2e7aa4b74230fc77e894f34a838b268c25ec8eeb8" 20 | solver-name = "gps-cdcl" 21 | solver-version = 1 22 | -------------------------------------------------------------------------------- /vendor/github.com/json-iterator/go/Gopkg.toml: -------------------------------------------------------------------------------- 1 | # Gopkg.toml example 2 | # 3 | # Refer to https://github.com/golang/dep/blob/master/docs/Gopkg.toml.md 4 | # for detailed Gopkg.toml documentation. 5 | # 6 | # required = ["github.com/user/thing/cmd/thing"] 7 | # ignored = ["github.com/user/project/pkgX", "bitbucket.org/user/project/pkgA/pkgY"] 8 | # 9 | # [[constraint]] 10 | # name = "github.com/user/project" 11 | # version = "1.0.0" 12 | # 13 | # [[constraint]] 14 | # name = "github.com/user/project2" 15 | # branch = "dev" 16 | # source = "github.com/myfork/project2" 17 | # 18 | # [[override]] 19 | # name = "github.com/x/y" 20 | # version = "2.4.0" 21 | 22 | ignored = ["github.com/davecgh/go-spew*","github.com/google/gofuzz*","github.com/stretchr/testify*"] 23 | 24 | [[constraint]] 25 | name = "github.com/modern-go/reflect2" 26 | version = "1.0.1" 27 | -------------------------------------------------------------------------------- /vendor/github.com/json-iterator/go/build.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | set -x 4 | 5 | if [ ! -d /tmp/build-golang/src/github.com/json-iterator ]; then 6 | mkdir -p /tmp/build-golang/src/github.com/json-iterator 7 | ln -s $PWD /tmp/build-golang/src/github.com/json-iterator/go 8 | fi 9 | export GOPATH=/tmp/build-golang 10 | go get -u github.com/golang/dep/cmd/dep 11 | cd /tmp/build-golang/src/github.com/json-iterator/go 12 | exec $GOPATH/bin/dep ensure -update 13 | -------------------------------------------------------------------------------- /vendor/github.com/json-iterator/go/test.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e 4 | echo "" > coverage.txt 5 | 6 | for d in $(go list ./... | grep -v vendor); do 7 | go test -coverprofile=profile.out -coverpkg=github.com/json-iterator/go $d 8 | if [ -f profile.out ]; then 9 | cat profile.out >> coverage.txt 10 | rm profile.out 11 | fi 12 | done 13 | -------------------------------------------------------------------------------- /vendor/github.com/klauspost/compress/.gitattributes: -------------------------------------------------------------------------------- 1 | * -text 2 | *.bin -text -diff 3 | -------------------------------------------------------------------------------- /vendor/github.com/klauspost/compress/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | 10 | # Architecture specific extensions/prefixes 11 | *.[568vq] 12 | [568vq].out 13 | 14 | *.cgo1.go 15 | *.cgo2.c 16 | _cgo_defun.c 17 | _cgo_gotypes.go 18 | _cgo_export.* 19 | 20 | _testmain.go 21 | 22 | *.exe 23 | *.test 24 | *.prof 25 | /s2/cmd/_s2sx/sfx-exe 26 | -------------------------------------------------------------------------------- /vendor/github.com/klauspost/compress/gen.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | cd s2/cmd/_s2sx/ || exit 1 4 | go generate . 5 | -------------------------------------------------------------------------------- /vendor/github.com/klauspost/compress/huff0/.gitignore: -------------------------------------------------------------------------------- 1 | /huff0-fuzz.zip 2 | -------------------------------------------------------------------------------- /vendor/github.com/klauspost/compress/s2sx.mod: -------------------------------------------------------------------------------- 1 | module github.com/klauspost/compress 2 | 3 | go 1.16 4 | 5 | -------------------------------------------------------------------------------- /vendor/github.com/klauspost/compress/s2sx.sum: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/klauspost/compress/s2sx.sum -------------------------------------------------------------------------------- /vendor/github.com/klauspost/compress/zstd/internal/xxhash/xxhash_amd64.go: -------------------------------------------------------------------------------- 1 | //go:build !appengine && gc && !purego 2 | // +build !appengine,gc,!purego 3 | 4 | package xxhash 5 | 6 | // Sum64 computes the 64-bit xxHash digest of b. 7 | // 8 | //go:noescape 9 | func Sum64(b []byte) uint64 10 | 11 | //go:noescape 12 | func writeBlocks(d *Digest, b []byte) int 13 | -------------------------------------------------------------------------------- /vendor/github.com/klauspost/compress/zstd/internal/xxhash/xxhash_safe.go: -------------------------------------------------------------------------------- 1 | package xxhash 2 | 3 | // Sum64String computes the 64-bit xxHash digest of s. 4 | func Sum64String(s string) uint64 { 5 | return Sum64([]byte(s)) 6 | } 7 | 8 | // WriteString adds more data to d. It always returns len(s), nil. 9 | func (d *Digest) WriteString(s string) (n int, err error) { 10 | return d.Write([]byte(s)) 11 | } 12 | -------------------------------------------------------------------------------- /vendor/github.com/leodido/go-urn/.gitignore: -------------------------------------------------------------------------------- 1 | *.exe 2 | *.dll 3 | *.so 4 | *.dylib 5 | 6 | *.test 7 | 8 | *.out 9 | *.txt 10 | 11 | vendor/ -------------------------------------------------------------------------------- /vendor/github.com/leodido/go-urn/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | 3 | go: 4 | - 1.13.x 5 | - 1.14.x 6 | - 1.15.x 7 | - tip 8 | 9 | before_install: 10 | - go get -t -v ./... 11 | 12 | script: 13 | - go test -race -coverprofile=coverage.txt -covermode=atomic 14 | 15 | after_success: 16 | - bash <(curl -s https://codecov.io/bash) -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-colorable/go.test.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e 4 | echo "" > coverage.txt 5 | 6 | for d in $(go list ./... | grep -v vendor); do 7 | go test -race -coverprofile=profile.out -covermode=atomic "$d" 8 | if [ -f profile.out ]; then 9 | cat profile.out >> coverage.txt 10 | rm profile.out 11 | fi 12 | done 13 | -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-isatty/doc.go: -------------------------------------------------------------------------------- 1 | // Package isatty implements interface to isatty 2 | package isatty 3 | -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-isatty/go.test.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e 4 | echo "" > coverage.txt 5 | 6 | for d in $(go list ./... | grep -v vendor); do 7 | go test -race -coverprofile=profile.out -covermode=atomic "$d" 8 | if [ -f profile.out ]; then 9 | cat profile.out >> coverage.txt 10 | rm profile.out 11 | fi 12 | done 13 | -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-isatty/isatty_bsd.go: -------------------------------------------------------------------------------- 1 | //go:build (darwin || freebsd || openbsd || netbsd || dragonfly || hurd) && !appengine 2 | // +build darwin freebsd openbsd netbsd dragonfly hurd 3 | // +build !appengine 4 | 5 | package isatty 6 | 7 | import "golang.org/x/sys/unix" 8 | 9 | // IsTerminal return true if the file descriptor is terminal. 10 | func IsTerminal(fd uintptr) bool { 11 | _, err := unix.IoctlGetTermios(int(fd), unix.TIOCGETA) 12 | return err == nil 13 | } 14 | 15 | // IsCygwinTerminal return true if the file descriptor is a cygwin or msys2 16 | // terminal. This is also always false on this environment. 17 | func IsCygwinTerminal(fd uintptr) bool { 18 | return false 19 | } 20 | -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-isatty/isatty_others.go: -------------------------------------------------------------------------------- 1 | //go:build appengine || js || nacl || wasm 2 | // +build appengine js nacl wasm 3 | 4 | package isatty 5 | 6 | // IsTerminal returns true if the file descriptor is terminal which 7 | // is always false on js and appengine classic which is a sandboxed PaaS. 8 | func IsTerminal(fd uintptr) bool { 9 | return false 10 | } 11 | 12 | // IsCygwinTerminal() return true if the file descriptor is a cygwin or msys2 13 | // terminal. This is also always false on this environment. 14 | func IsCygwinTerminal(fd uintptr) bool { 15 | return false 16 | } 17 | -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-isatty/isatty_plan9.go: -------------------------------------------------------------------------------- 1 | //go:build plan9 2 | // +build plan9 3 | 4 | package isatty 5 | 6 | import ( 7 | "syscall" 8 | ) 9 | 10 | // IsTerminal returns true if the given file descriptor is a terminal. 11 | func IsTerminal(fd uintptr) bool { 12 | path, err := syscall.Fd2path(int(fd)) 13 | if err != nil { 14 | return false 15 | } 16 | return path == "/dev/cons" || path == "/mnt/term/dev/cons" 17 | } 18 | 19 | // IsCygwinTerminal return true if the file descriptor is a cygwin or msys2 20 | // terminal. This is also always false on this environment. 21 | func IsCygwinTerminal(fd uintptr) bool { 22 | return false 23 | } 24 | -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-isatty/isatty_solaris.go: -------------------------------------------------------------------------------- 1 | //go:build solaris && !appengine 2 | // +build solaris,!appengine 3 | 4 | package isatty 5 | 6 | import ( 7 | "golang.org/x/sys/unix" 8 | ) 9 | 10 | // IsTerminal returns true if the given file descriptor is a terminal. 11 | // see: https://src.illumos.org/source/xref/illumos-gate/usr/src/lib/libc/port/gen/isatty.c 12 | func IsTerminal(fd uintptr) bool { 13 | _, err := unix.IoctlGetTermio(int(fd), unix.TCGETA) 14 | return err == nil 15 | } 16 | 17 | // IsCygwinTerminal return true if the file descriptor is a cygwin or msys2 18 | // terminal. This is also always false on this environment. 19 | func IsCygwinTerminal(fd uintptr) bool { 20 | return false 21 | } 22 | -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-isatty/isatty_tcgets.go: -------------------------------------------------------------------------------- 1 | //go:build (linux || aix || zos) && !appengine 2 | // +build linux aix zos 3 | // +build !appengine 4 | 5 | package isatty 6 | 7 | import "golang.org/x/sys/unix" 8 | 9 | // IsTerminal return true if the file descriptor is terminal. 10 | func IsTerminal(fd uintptr) bool { 11 | _, err := unix.IoctlGetTermios(int(fd), unix.TCGETS) 12 | return err == nil 13 | } 14 | 15 | // IsCygwinTerminal return true if the file descriptor is a cygwin or msys2 16 | // terminal. This is also always false on this environment. 17 | func IsCygwinTerminal(fd uintptr) bool { 18 | return false 19 | } 20 | -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-runewidth/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | sudo: false 3 | go: 4 | - 1.13.x 5 | - tip 6 | 7 | before_install: 8 | - go get -t -v ./... 9 | 10 | script: 11 | - go generate 12 | - git diff --cached --exit-code 13 | - ./go.test.sh 14 | 15 | after_success: 16 | - bash <(curl -s https://codecov.io/bash) 17 | -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-runewidth/go.test.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e 4 | echo "" > coverage.txt 5 | 6 | for d in $(go list ./... | grep -v vendor); do 7 | go test -race -coverprofile=profile.out -covermode=atomic "$d" 8 | if [ -f profile.out ]; then 9 | cat profile.out >> coverage.txt 10 | rm profile.out 11 | fi 12 | done 13 | -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-runewidth/runewidth_appengine.go: -------------------------------------------------------------------------------- 1 | // +build appengine 2 | 3 | package runewidth 4 | 5 | // IsEastAsian return true if the current locale is CJK 6 | func IsEastAsian() bool { 7 | return false 8 | } 9 | -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-runewidth/runewidth_js.go: -------------------------------------------------------------------------------- 1 | // +build js 2 | // +build !appengine 3 | 4 | package runewidth 5 | 6 | func IsEastAsian() bool { 7 | // TODO: Implement this for the web. Detect east asian in a compatible way, and return true. 8 | return false 9 | } 10 | -------------------------------------------------------------------------------- /vendor/github.com/mattn/go-runewidth/runewidth_windows.go: -------------------------------------------------------------------------------- 1 | // +build windows 2 | // +build !appengine 3 | 4 | package runewidth 5 | 6 | import ( 7 | "syscall" 8 | ) 9 | 10 | var ( 11 | kernel32 = syscall.NewLazyDLL("kernel32") 12 | procGetConsoleOutputCP = kernel32.NewProc("GetConsoleOutputCP") 13 | ) 14 | 15 | // IsEastAsian return true if the current locale is CJK 16 | func IsEastAsian() bool { 17 | r1, _, _ := procGetConsoleOutputCP.Call() 18 | if r1 == 0 { 19 | return false 20 | } 21 | 22 | switch int(r1) { 23 | case 932, 51932, 936, 949, 950: 24 | return true 25 | } 26 | 27 | return false 28 | } 29 | -------------------------------------------------------------------------------- /vendor/github.com/modern-go/concurrent/README.md: -------------------------------------------------------------------------------- 1 | # concurrent 2 | concurrency utilities 3 | -------------------------------------------------------------------------------- /vendor/github.com/modern-go/concurrent/executor.go: -------------------------------------------------------------------------------- 1 | package concurrent 2 | 3 | import "context" 4 | 5 | type Executor interface { 6 | Go(handler func(ctx context.Context)) 7 | } -------------------------------------------------------------------------------- /vendor/github.com/modern-go/concurrent/go_above_19.go: -------------------------------------------------------------------------------- 1 | //+build go1.9 2 | 3 | package concurrent 4 | 5 | import "sync" 6 | 7 | type Map struct { 8 | sync.Map 9 | } 10 | 11 | func NewMap() *Map { 12 | return &Map{} 13 | } -------------------------------------------------------------------------------- /vendor/github.com/modern-go/concurrent/go_below_19.go: -------------------------------------------------------------------------------- 1 | //+build !go1.9 2 | 3 | package concurrent 4 | 5 | import "sync" 6 | 7 | type Map struct { 8 | lock sync.RWMutex 9 | data map[interface{}]interface{} 10 | } 11 | 12 | func NewMap() *Map { 13 | return &Map{ 14 | data: make(map[interface{}]interface{}, 32), 15 | } 16 | } 17 | 18 | func (m *Map) Load(key interface{}) (elem interface{}, found bool) { 19 | m.lock.RLock() 20 | elem, found = m.data[key] 21 | m.lock.RUnlock() 22 | return 23 | } 24 | 25 | func (m *Map) Store(key interface{}, elem interface{}) { 26 | m.lock.Lock() 27 | m.data[key] = elem 28 | m.lock.Unlock() 29 | } 30 | 31 | -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/.gitignore: -------------------------------------------------------------------------------- 1 | /vendor 2 | /coverage.txt 3 | -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | 3 | go: 4 | - 1.9.x 5 | - 1.x 6 | 7 | before_install: 8 | - go get -t -v ./... 9 | - go get -t -v github.com/modern-go/reflect2-tests/... 10 | 11 | script: 12 | - ./test.sh 13 | 14 | after_success: 15 | - bash <(curl -s https://codecov.io/bash) 16 | -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/Gopkg.lock: -------------------------------------------------------------------------------- 1 | # This file is autogenerated, do not edit; changes may be undone by the next 'dep ensure'. 2 | 3 | 4 | [solve-meta] 5 | analyzer-name = "dep" 6 | analyzer-version = 1 7 | input-imports = [] 8 | solver-name = "gps-cdcl" 9 | solver-version = 1 10 | -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/Gopkg.toml: -------------------------------------------------------------------------------- 1 | # Gopkg.toml example 2 | # 3 | # Refer to https://golang.github.io/dep/docs/Gopkg.toml.html 4 | # for detailed Gopkg.toml documentation. 5 | # 6 | # required = ["github.com/user/thing/cmd/thing"] 7 | # ignored = ["github.com/user/project/pkgX", "bitbucket.org/user/project/pkgA/pkgY"] 8 | # 9 | # [[constraint]] 10 | # name = "github.com/user/project" 11 | # version = "1.0.0" 12 | # 13 | # [[constraint]] 14 | # name = "github.com/user/project2" 15 | # branch = "dev" 16 | # source = "github.com/myfork/project2" 17 | # 18 | # [[override]] 19 | # name = "github.com/x/y" 20 | # version = "2.4.0" 21 | # 22 | # [prune] 23 | # non-go = false 24 | # go-tests = true 25 | # unused-packages = true 26 | 27 | ignored = [] 28 | 29 | [prune] 30 | go-tests = true 31 | unused-packages = true 32 | -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/go_above_118.go: -------------------------------------------------------------------------------- 1 | //+build go1.18 2 | 3 | package reflect2 4 | 5 | import ( 6 | "unsafe" 7 | ) 8 | 9 | // m escapes into the return value, but the caller of mapiterinit 10 | // doesn't let the return value escape. 11 | //go:noescape 12 | //go:linkname mapiterinit reflect.mapiterinit 13 | func mapiterinit(rtype unsafe.Pointer, m unsafe.Pointer, it *hiter) 14 | 15 | func (type2 *UnsafeMapType) UnsafeIterate(obj unsafe.Pointer) MapIterator { 16 | var it hiter 17 | mapiterinit(type2.rtype, *(*unsafe.Pointer)(obj), &it) 18 | return &UnsafeMapIterator{ 19 | hiter: &it, 20 | pKeyRType: type2.pKeyRType, 21 | pElemRType: type2.pElemRType, 22 | } 23 | } -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/go_above_19.go: -------------------------------------------------------------------------------- 1 | //+build go1.9 2 | 3 | package reflect2 4 | 5 | import ( 6 | "unsafe" 7 | ) 8 | 9 | //go:linkname resolveTypeOff reflect.resolveTypeOff 10 | func resolveTypeOff(rtype unsafe.Pointer, off int32) unsafe.Pointer 11 | 12 | //go:linkname makemap reflect.makemap 13 | func makemap(rtype unsafe.Pointer, cap int) (m unsafe.Pointer) 14 | 15 | func makeMapWithSize(rtype unsafe.Pointer, cap int) unsafe.Pointer { 16 | return makemap(rtype, cap) 17 | } 18 | -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/go_below_118.go: -------------------------------------------------------------------------------- 1 | //+build !go1.18 2 | 3 | package reflect2 4 | 5 | import ( 6 | "unsafe" 7 | ) 8 | 9 | // m escapes into the return value, but the caller of mapiterinit 10 | // doesn't let the return value escape. 11 | //go:noescape 12 | //go:linkname mapiterinit reflect.mapiterinit 13 | func mapiterinit(rtype unsafe.Pointer, m unsafe.Pointer) (val *hiter) 14 | 15 | func (type2 *UnsafeMapType) UnsafeIterate(obj unsafe.Pointer) MapIterator { 16 | return &UnsafeMapIterator{ 17 | hiter: mapiterinit(type2.rtype, *(*unsafe.Pointer)(obj)), 18 | pKeyRType: type2.pKeyRType, 19 | pElemRType: type2.pElemRType, 20 | } 21 | } -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/reflect2_amd64.s: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/modern-go/reflect2/reflect2_amd64.s -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/relfect2_386.s: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/modern-go/reflect2/relfect2_386.s -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/relfect2_amd64p32.s: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/modern-go/reflect2/relfect2_amd64p32.s -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/relfect2_arm.s: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/modern-go/reflect2/relfect2_arm.s -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/relfect2_arm64.s: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/modern-go/reflect2/relfect2_arm64.s -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/relfect2_mips64x.s: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/modern-go/reflect2/relfect2_mips64x.s -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/relfect2_mipsx.s: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/modern-go/reflect2/relfect2_mipsx.s -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/relfect2_ppc64x.s: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/modern-go/reflect2/relfect2_ppc64x.s -------------------------------------------------------------------------------- /vendor/github.com/modern-go/reflect2/relfect2_s390x.s: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/modern-go/reflect2/relfect2_s390x.s -------------------------------------------------------------------------------- /vendor/github.com/montanaflynn/stats/.gitignore: -------------------------------------------------------------------------------- 1 | coverage.out 2 | coverage.txt 3 | release-notes.txt 4 | .directory 5 | .chglog 6 | .vscode 7 | .DS_Store -------------------------------------------------------------------------------- /vendor/github.com/montanaflynn/stats/Makefile: -------------------------------------------------------------------------------- 1 | .PHONY: all 2 | 3 | default: test lint 4 | 5 | format: 6 | go fmt . 7 | 8 | test: 9 | go test -race 10 | 11 | check: format test 12 | 13 | benchmark: 14 | go test -bench=. -benchmem 15 | 16 | coverage: 17 | go test -coverprofile=coverage.out 18 | go tool cover -html="coverage.out" 19 | 20 | lint: format 21 | golangci-lint run . 22 | 23 | docs: 24 | godoc2md github.com/montanaflynn/stats | sed -e s#src/target/##g > DOCUMENTATION.md 25 | 26 | release: 27 | git-chglog --output CHANGELOG.md --next-tag ${TAG} 28 | git add CHANGELOG.md 29 | git commit -m "Update changelog with ${TAG} changes" 30 | git tag ${TAG} 31 | git-chglog $(TAG) | tail -n +4 | gsed '1s/^/$(TAG)\n/gm' > release-notes.txt 32 | git push origin master ${TAG} 33 | hub release create --copy -F release-notes.txt ${TAG} 34 | 35 | -------------------------------------------------------------------------------- /vendor/github.com/montanaflynn/stats/cumulative_sum.go: -------------------------------------------------------------------------------- 1 | package stats 2 | 3 | // CumulativeSum calculates the cumulative sum of the input slice 4 | func CumulativeSum(input Float64Data) ([]float64, error) { 5 | 6 | if input.Len() == 0 { 7 | return Float64Data{}, EmptyInput 8 | } 9 | 10 | cumSum := make([]float64, input.Len()) 11 | 12 | for i, val := range input { 13 | if i == 0 { 14 | cumSum[i] = val 15 | } else { 16 | cumSum[i] = cumSum[i-1] + val 17 | } 18 | } 19 | 20 | return cumSum, nil 21 | } 22 | -------------------------------------------------------------------------------- /vendor/github.com/montanaflynn/stats/doc.go: -------------------------------------------------------------------------------- 1 | /* 2 | Package stats is a well tested and comprehensive 3 | statistics library package with no dependencies. 4 | 5 | Example Usage: 6 | 7 | // start with some source data to use 8 | data := []float64{1.0, 2.1, 3.2, 4.823, 4.1, 5.8} 9 | 10 | // you could also use different types like this 11 | // data := stats.LoadRawData([]int{1, 2, 3, 4, 5}) 12 | // data := stats.LoadRawData([]interface{}{1.1, "2", 3}) 13 | // etc... 14 | 15 | median, _ := stats.Median(data) 16 | fmt.Println(median) // 3.65 17 | 18 | roundedMedian, _ := stats.Round(median, 0) 19 | fmt.Println(roundedMedian) // 4 20 | 21 | MIT License Copyright (c) 2014-2020 Montana Flynn (https://montanaflynn.com) 22 | */ 23 | package stats 24 | -------------------------------------------------------------------------------- /vendor/github.com/montanaflynn/stats/entropy.go: -------------------------------------------------------------------------------- 1 | package stats 2 | 3 | import "math" 4 | 5 | // Entropy provides calculation of the entropy 6 | func Entropy(input Float64Data) (float64, error) { 7 | input, err := normalize(input) 8 | if err != nil { 9 | return math.NaN(), err 10 | } 11 | var result float64 12 | for i := 0; i < input.Len(); i++ { 13 | v := input.Get(i) 14 | if v == 0 { 15 | continue 16 | } 17 | result += (v * math.Log(v)) 18 | } 19 | return -result, nil 20 | } 21 | 22 | func normalize(input Float64Data) (Float64Data, error) { 23 | sum, err := input.Sum() 24 | if err != nil { 25 | return Float64Data{}, err 26 | } 27 | for i := 0; i < input.Len(); i++ { 28 | input[i] = input[i] / sum 29 | } 30 | return input, nil 31 | } 32 | -------------------------------------------------------------------------------- /vendor/github.com/montanaflynn/stats/max.go: -------------------------------------------------------------------------------- 1 | package stats 2 | 3 | import ( 4 | "math" 5 | ) 6 | 7 | // Max finds the highest number in a slice 8 | func Max(input Float64Data) (max float64, err error) { 9 | 10 | // Return an error if there are no numbers 11 | if input.Len() == 0 { 12 | return math.NaN(), EmptyInputErr 13 | } 14 | 15 | // Get the first value as the starting point 16 | max = input.Get(0) 17 | 18 | // Loop and replace higher values 19 | for i := 1; i < input.Len(); i++ { 20 | if input.Get(i) > max { 21 | max = input.Get(i) 22 | } 23 | } 24 | 25 | return max, nil 26 | } 27 | -------------------------------------------------------------------------------- /vendor/github.com/montanaflynn/stats/median.go: -------------------------------------------------------------------------------- 1 | package stats 2 | 3 | import "math" 4 | 5 | // Median gets the median number in a slice of numbers 6 | func Median(input Float64Data) (median float64, err error) { 7 | 8 | // Start by sorting a copy of the slice 9 | c := sortedCopy(input) 10 | 11 | // No math is needed if there are no numbers 12 | // For even numbers we add the two middle numbers 13 | // and divide by two using the mean function above 14 | // For odd numbers we just use the middle number 15 | l := len(c) 16 | if l == 0 { 17 | return math.NaN(), EmptyInputErr 18 | } else if l%2 == 0 { 19 | median, _ = Mean(c[l/2-1 : l/2+1]) 20 | } else { 21 | median = c[l/2] 22 | } 23 | 24 | return median, nil 25 | } 26 | -------------------------------------------------------------------------------- /vendor/github.com/montanaflynn/stats/min.go: -------------------------------------------------------------------------------- 1 | package stats 2 | 3 | import "math" 4 | 5 | // Min finds the lowest number in a set of data 6 | func Min(input Float64Data) (min float64, err error) { 7 | 8 | // Get the count of numbers in the slice 9 | l := input.Len() 10 | 11 | // Return an error if there are no numbers 12 | if l == 0 { 13 | return math.NaN(), EmptyInputErr 14 | } 15 | 16 | // Get the first value as the starting point 17 | min = input.Get(0) 18 | 19 | // Iterate until done checking for a lower value 20 | for i := 1; i < l; i++ { 21 | if input.Get(i) < min { 22 | min = input.Get(i) 23 | } 24 | } 25 | return min, nil 26 | } 27 | -------------------------------------------------------------------------------- /vendor/github.com/montanaflynn/stats/sigmoid.go: -------------------------------------------------------------------------------- 1 | package stats 2 | 3 | import "math" 4 | 5 | // Sigmoid returns the input values in the range of -1 to 1 6 | // along the sigmoid or s-shaped curve, commonly used in 7 | // machine learning while training neural networks as an 8 | // activation function. 9 | func Sigmoid(input Float64Data) ([]float64, error) { 10 | if input.Len() == 0 { 11 | return Float64Data{}, EmptyInput 12 | } 13 | s := make([]float64, len(input)) 14 | for i, v := range input { 15 | s[i] = 1 / (1 + math.Exp(-v)) 16 | } 17 | return s, nil 18 | } 19 | -------------------------------------------------------------------------------- /vendor/github.com/montanaflynn/stats/softmax.go: -------------------------------------------------------------------------------- 1 | package stats 2 | 3 | import "math" 4 | 5 | // SoftMax returns the input values in the range of 0 to 1 6 | // with sum of all the probabilities being equal to one. It 7 | // is commonly used in machine learning neural networks. 8 | func SoftMax(input Float64Data) ([]float64, error) { 9 | if input.Len() == 0 { 10 | return Float64Data{}, EmptyInput 11 | } 12 | 13 | s := 0.0 14 | c, _ := Max(input) 15 | for _, e := range input { 16 | s += math.Exp(e - c) 17 | } 18 | 19 | sm := make([]float64, len(input)) 20 | for i, v := range input { 21 | sm[i] = math.Exp(v-c) / s 22 | } 23 | 24 | return sm, nil 25 | } 26 | -------------------------------------------------------------------------------- /vendor/github.com/montanaflynn/stats/sum.go: -------------------------------------------------------------------------------- 1 | package stats 2 | 3 | import "math" 4 | 5 | // Sum adds all the numbers of a slice together 6 | func Sum(input Float64Data) (sum float64, err error) { 7 | 8 | if input.Len() == 0 { 9 | return math.NaN(), EmptyInputErr 10 | } 11 | 12 | // Add em up 13 | for _, n := range input { 14 | sum += n 15 | } 16 | 17 | return sum, nil 18 | } 19 | -------------------------------------------------------------------------------- /vendor/github.com/olekukonko/tablewriter/.gitignore: -------------------------------------------------------------------------------- 1 | # Created by .ignore support plugin (hsz.mobi) 2 | ### Go template 3 | # Binaries for programs and plugins 4 | *.exe 5 | *.exe~ 6 | *.dll 7 | *.so 8 | *.dylib 9 | 10 | # Test binary, build with `go test -c` 11 | *.test 12 | 13 | # Output of the go coverage tool, specifically when used with LiteIDE 14 | *.out 15 | 16 | -------------------------------------------------------------------------------- /vendor/github.com/olekukonko/tablewriter/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | arch: 3 | - ppc64le 4 | - amd64 5 | go: 6 | - 1.3 7 | - 1.4 8 | - 1.5 9 | - 1.6 10 | - 1.7 11 | - 1.8 12 | - 1.9 13 | - "1.10" 14 | - tip 15 | jobs: 16 | exclude : 17 | - arch : ppc64le 18 | go : 19 | - 1.3 20 | - arch : ppc64le 21 | go : 22 | - 1.4 23 | -------------------------------------------------------------------------------- /vendor/github.com/pelletier/go-toml/v2/.dockerignore: -------------------------------------------------------------------------------- 1 | cmd/tomll/tomll 2 | cmd/tomljson/tomljson 3 | -------------------------------------------------------------------------------- /vendor/github.com/pelletier/go-toml/v2/.gitattributes: -------------------------------------------------------------------------------- 1 | * text=auto 2 | 3 | benchmark/benchmark.toml text eol=lf 4 | testdata/** text eol=lf 5 | -------------------------------------------------------------------------------- /vendor/github.com/pelletier/go-toml/v2/.gitignore: -------------------------------------------------------------------------------- 1 | test_program/test_program_bin 2 | fuzz/ 3 | cmd/tomll/tomll 4 | cmd/tomljson/tomljson 5 | cmd/tomltestgen/tomltestgen 6 | dist -------------------------------------------------------------------------------- /vendor/github.com/pelletier/go-toml/v2/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM scratch 2 | ENV PATH "$PATH:/bin" 3 | COPY tomll /bin/tomll 4 | COPY tomljson /bin/tomljson 5 | COPY jsontoml /bin/jsontoml 6 | -------------------------------------------------------------------------------- /vendor/github.com/pelletier/go-toml/v2/SECURITY.md: -------------------------------------------------------------------------------- 1 | # Security Policy 2 | 3 | ## Supported Versions 4 | 5 | Use this section to tell people about which versions of your project are 6 | currently being supported with security updates. 7 | 8 | | Version | Supported | 9 | | ---------- | ------------------ | 10 | | Latest 2.x | :white_check_mark: | 11 | | All 1.x | :x: | 12 | | All 0.x | :x: | 13 | 14 | ## Reporting a Vulnerability 15 | 16 | Email a vulnerability report to `security@pelletier.codes`. Make sure to include 17 | as many details as possible to reproduce the vulnerability. This is a 18 | side-project: I will try to get back to you as quickly as possible, time 19 | permitting in my personal life. Providing a working patch helps very much! 20 | -------------------------------------------------------------------------------- /vendor/github.com/pelletier/go-toml/v2/doc.go: -------------------------------------------------------------------------------- 1 | // Package toml is a library to read and write TOML documents. 2 | package toml 3 | -------------------------------------------------------------------------------- /vendor/github.com/pelletier/go-toml/v2/internal/danger/typeid.go: -------------------------------------------------------------------------------- 1 | package danger 2 | 3 | import ( 4 | "reflect" 5 | "unsafe" 6 | ) 7 | 8 | // typeID is used as key in encoder and decoder caches to enable using 9 | // the optimize runtime.mapaccess2_fast64 function instead of the more 10 | // expensive lookup if we were to use reflect.Type as map key. 11 | // 12 | // typeID holds the pointer to the reflect.Type value, which is unique 13 | // in the program. 14 | // 15 | // https://github.com/segmentio/encoding/blob/master/json/codec.go#L59-L61 16 | type TypeID unsafe.Pointer 17 | 18 | func MakeTypeID(t reflect.Type) TypeID { 19 | // reflect.Type has the fields: 20 | // typ unsafe.Pointer 21 | // ptr unsafe.Pointer 22 | return TypeID((*[2]unsafe.Pointer)(unsafe.Pointer(&t))[1]) 23 | } 24 | -------------------------------------------------------------------------------- /vendor/github.com/pelletier/go-toml/v2/internal/tracker/tracker.go: -------------------------------------------------------------------------------- 1 | package tracker 2 | -------------------------------------------------------------------------------- /vendor/github.com/pelletier/go-toml/v2/types.go: -------------------------------------------------------------------------------- 1 | package toml 2 | 3 | import ( 4 | "encoding" 5 | "reflect" 6 | "time" 7 | ) 8 | 9 | var timeType = reflect.TypeOf(time.Time{}) 10 | var textMarshalerType = reflect.TypeOf(new(encoding.TextMarshaler)).Elem() 11 | var textUnmarshalerType = reflect.TypeOf(new(encoding.TextUnmarshaler)).Elem() 12 | var mapStringInterfaceType = reflect.TypeOf(map[string]interface{}{}) 13 | var sliceInterfaceType = reflect.TypeOf([]interface{}{}) 14 | var stringType = reflect.TypeOf("") 15 | -------------------------------------------------------------------------------- /vendor/github.com/pkg/errors/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | 10 | # Architecture specific extensions/prefixes 11 | *.[568vq] 12 | [568vq].out 13 | 14 | *.cgo1.go 15 | *.cgo2.c 16 | _cgo_defun.c 17 | _cgo_gotypes.go 18 | _cgo_export.* 19 | 20 | _testmain.go 21 | 22 | *.exe 23 | *.test 24 | *.prof 25 | -------------------------------------------------------------------------------- /vendor/github.com/pkg/errors/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | go_import_path: github.com/pkg/errors 3 | go: 4 | - 1.11.x 5 | - 1.12.x 6 | - 1.13.x 7 | - tip 8 | 9 | script: 10 | - make check 11 | -------------------------------------------------------------------------------- /vendor/github.com/pkg/errors/appveyor.yml: -------------------------------------------------------------------------------- 1 | version: build-{build}.{branch} 2 | 3 | clone_folder: C:\gopath\src\github.com\pkg\errors 4 | shallow_clone: true # for startup speed 5 | 6 | environment: 7 | GOPATH: C:\gopath 8 | 9 | platform: 10 | - x64 11 | 12 | # http://www.appveyor.com/docs/installed-software 13 | install: 14 | # some helpful output for debugging builds 15 | - go version 16 | - go env 17 | # pre-installed MinGW at C:\MinGW is 32bit only 18 | # but MSYS2 at C:\msys64 has mingw64 19 | - set PATH=C:\msys64\mingw64\bin;%PATH% 20 | - gcc --version 21 | - g++ --version 22 | 23 | build_script: 24 | - go install -v ./... 25 | 26 | test_script: 27 | - set PATH=C:\gopath\bin;%PATH% 28 | - go test -v ./... 29 | 30 | #artifacts: 31 | # - path: '%GOPATH%\bin\*.exe' 32 | deploy: off 33 | -------------------------------------------------------------------------------- /vendor/github.com/quasilyte/go-ruleguard/dsl/bundle.go: -------------------------------------------------------------------------------- 1 | package dsl 2 | 3 | // Bundle is a rules file export manifest. 4 | type Bundle struct { 5 | // TODO: figure out which fields we might want to add here. 6 | } 7 | 8 | // ImportRules imports all rules from the bundle and prefixes them with a specified string. 9 | // 10 | // Empty string prefix is something like "dot import" in Go. 11 | // Group name collisions will result in an error. 12 | // 13 | // Only packages that have an exported Bundle variable can be imported. 14 | // 15 | // Note: right now imported bundle can't import other bundles. 16 | // This is not a fundamental limitation but rather a precaution 17 | // measure before we understand how it should work better. 18 | // If you need this feature, please open an issue at github.com/quasilyte/go-ruleguard. 19 | func ImportRules(prefix string, bundle Bundle) {} 20 | -------------------------------------------------------------------------------- /vendor/github.com/quasilyte/go-ruleguard/dsl/do.go: -------------------------------------------------------------------------------- 1 | package dsl 2 | 3 | import ( 4 | "github.com/quasilyte/go-ruleguard/dsl/types" 5 | ) 6 | 7 | type DoContext struct{} 8 | 9 | func (*DoContext) Var(varname string) *DoVar { return nil } 10 | 11 | func (*DoContext) SetReport(report string) {} 12 | 13 | func (*DoContext) SetSuggest(suggest string) {} 14 | 15 | type DoVar struct{} 16 | 17 | func (*DoVar) Text() string { return "" } 18 | 19 | func (*DoVar) Type() types.Type { return nil } 20 | -------------------------------------------------------------------------------- /vendor/github.com/quasilyte/go-ruleguard/dsl/internal.go: -------------------------------------------------------------------------------- 1 | package dsl 2 | 3 | var boolResult bool 4 | var intResult int 5 | 6 | var underlyingType ExprType 7 | -------------------------------------------------------------------------------- /vendor/github.com/quasilyte/go-ruleguard/dsl/types/type_impl.go: -------------------------------------------------------------------------------- 1 | package types 2 | 3 | // Method stubs to make various types implement Type interface. 4 | // 5 | // Nothing interesting here, hence it's moved to a separate file. 6 | 7 | func (*Array) String() string { return "" } 8 | func (*Slice) String() string { return "" } 9 | func (*Pointer) String() string { return "" } 10 | func (*Interface) String() string { return "" } 11 | func (*Struct) String() string { return "" } 12 | 13 | func (*Array) Underlying() Type { return nil } 14 | func (*Slice) Underlying() Type { return nil } 15 | func (*Pointer) Underlying() Type { return nil } 16 | func (*Interface) Underlying() Type { return nil } 17 | func (*Struct) Underlying() Type { return nil } 18 | -------------------------------------------------------------------------------- /vendor/github.com/rs/zerolog/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | tmp 10 | 11 | # Architecture specific extensions/prefixes 12 | *.[568vq] 13 | [568vq].out 14 | 15 | *.cgo1.go 16 | *.cgo2.c 17 | _cgo_defun.c 18 | _cgo_gotypes.go 19 | _cgo_export.* 20 | 21 | _testmain.go 22 | 23 | *.exe 24 | *.test 25 | *.prof 26 | -------------------------------------------------------------------------------- /vendor/github.com/rs/zerolog/example.jsonl: -------------------------------------------------------------------------------- 1 | {"time":"5:41PM","level":"info","message":"Starting listener","listen":":8080","pid":37556} 2 | {"time":"5:41PM","level":"debug","message":"Access","database":"myapp","host":"localhost:4962","pid":37556} 3 | {"time":"5:41PM","level":"info","message":"Access","method":"GET","path":"/users","pid":37556,"resp_time":23} 4 | {"time":"5:41PM","level":"info","message":"Access","method":"POST","path":"/posts","pid":37556,"resp_time":532} 5 | {"time":"5:41PM","level":"warn","message":"Slow request","method":"POST","path":"/posts","pid":37556,"resp_time":532} 6 | {"time":"5:41PM","level":"info","message":"Access","method":"GET","path":"/users","pid":37556,"resp_time":10} 7 | {"time":"5:41PM","level":"error","message":"Database connection lost","database":"myapp","pid":37556,"error":"connection reset by peer"} 8 | -------------------------------------------------------------------------------- /vendor/github.com/rs/zerolog/go112.go: -------------------------------------------------------------------------------- 1 | // +build go1.12 2 | 3 | package zerolog 4 | 5 | // Since go 1.12, some auto generated init functions are hidden from 6 | // runtime.Caller. 7 | const contextCallerSkipFrameCount = 2 8 | -------------------------------------------------------------------------------- /vendor/github.com/rs/zerolog/internal/cbor/base.go: -------------------------------------------------------------------------------- 1 | package cbor 2 | 3 | // JSONMarshalFunc is used to marshal interface to JSON encoded byte slice. 4 | // Making it package level instead of embedded in Encoder brings 5 | // some extra efforts at importing, but avoids value copy when the functions 6 | // of Encoder being invoked. 7 | // DO REMEMBER to set this variable at importing, or 8 | // you might get a nil pointer dereference panic at runtime. 9 | var JSONMarshalFunc func(v interface{}) ([]byte, error) 10 | 11 | type Encoder struct{} 12 | 13 | // AppendKey adds a key (string) to the binary encoded log message 14 | func (e Encoder) AppendKey(dst []byte, key string) []byte { 15 | if len(dst) < 1 { 16 | dst = e.AppendBeginMarker(dst) 17 | } 18 | return e.AppendString(dst, key) 19 | } 20 | -------------------------------------------------------------------------------- /vendor/github.com/rs/zerolog/internal/json/base.go: -------------------------------------------------------------------------------- 1 | package json 2 | 3 | // JSONMarshalFunc is used to marshal interface to JSON encoded byte slice. 4 | // Making it package level instead of embedded in Encoder brings 5 | // some extra efforts at importing, but avoids value copy when the functions 6 | // of Encoder being invoked. 7 | // DO REMEMBER to set this variable at importing, or 8 | // you might get a nil pointer dereference panic at runtime. 9 | var JSONMarshalFunc func(v interface{}) ([]byte, error) 10 | 11 | type Encoder struct{} 12 | 13 | // AppendKey appends a new key to the output JSON. 14 | func (e Encoder) AppendKey(dst []byte, key string) []byte { 15 | if dst[len(dst)-1] != '{' { 16 | dst = append(dst, ',') 17 | } 18 | return append(e.AppendString(dst, key), ':') 19 | } 20 | -------------------------------------------------------------------------------- /vendor/github.com/rs/zerolog/not_go112.go: -------------------------------------------------------------------------------- 1 | // +build !go1.12 2 | 3 | package zerolog 4 | 5 | const contextCallerSkipFrameCount = 3 6 | -------------------------------------------------------------------------------- /vendor/github.com/rs/zerolog/pretty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/rs/zerolog/pretty.png -------------------------------------------------------------------------------- /vendor/github.com/russross/blackfriday/v2/.gitignore: -------------------------------------------------------------------------------- 1 | *.out 2 | *.swp 3 | *.8 4 | *.6 5 | _obj 6 | _test* 7 | markdown 8 | tags 9 | -------------------------------------------------------------------------------- /vendor/github.com/russross/blackfriday/v2/.travis.yml: -------------------------------------------------------------------------------- 1 | sudo: false 2 | language: go 3 | go: 4 | - "1.10.x" 5 | - "1.11.x" 6 | - tip 7 | matrix: 8 | fast_finish: true 9 | allow_failures: 10 | - go: tip 11 | install: 12 | - # Do nothing. This is needed to prevent default install action "go get -t -v ./..." from happening here (we want it to happen inside script step). 13 | script: 14 | - go get -t -v ./... 15 | - diff -u <(echo -n) <(gofmt -d -s .) 16 | - go tool vet . 17 | - go test -v ./... 18 | -------------------------------------------------------------------------------- /vendor/github.com/samber/lo/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | before_install: 3 | - go mod download 4 | - make tools 5 | go: 6 | - "1.18" 7 | script: make test 8 | -------------------------------------------------------------------------------- /vendor/github.com/samber/lo/Dockerfile: -------------------------------------------------------------------------------- 1 | 2 | FROM golang:1.21.12 3 | 4 | WORKDIR /go/src/github.com/samber/lo 5 | 6 | COPY Makefile go.* ./ 7 | 8 | RUN make tools 9 | -------------------------------------------------------------------------------- /vendor/github.com/samber/lo/constraints.go: -------------------------------------------------------------------------------- 1 | package lo 2 | 3 | // Clonable defines a constraint of types having Clone() T method. 4 | type Clonable[T any] interface { 5 | Clone() T 6 | } 7 | -------------------------------------------------------------------------------- /vendor/github.com/samber/lo/internal/constraints/ordered_go118.go: -------------------------------------------------------------------------------- 1 | //go:build !go1.21 2 | 3 | package constraints 4 | 5 | // Ordered is a constraint that permits any ordered type: any type 6 | // that supports the operators < <= >= >. 7 | // If future releases of Go add new ordered types, 8 | // this constraint will be modified to include them. 9 | type Ordered interface { 10 | Integer | Float | ~string 11 | } 12 | -------------------------------------------------------------------------------- /vendor/github.com/samber/lo/internal/constraints/ordered_go121.go: -------------------------------------------------------------------------------- 1 | //go:build go1.21 2 | 3 | package constraints 4 | 5 | import ( 6 | "cmp" 7 | ) 8 | 9 | type Ordered = cmp.Ordered 10 | -------------------------------------------------------------------------------- /vendor/github.com/samber/lo/internal/rand/ordered_go118.go: -------------------------------------------------------------------------------- 1 | //go:build !go1.22 2 | 3 | package rand 4 | 5 | import "math/rand" 6 | 7 | func Shuffle(n int, swap func(i, j int)) { 8 | rand.Shuffle(n, swap) 9 | } 10 | 11 | func IntN(n int) int { 12 | // bearer:disable go_gosec_crypto_weak_random 13 | return rand.Intn(n) 14 | } 15 | -------------------------------------------------------------------------------- /vendor/github.com/samber/lo/internal/rand/ordered_go122.go: -------------------------------------------------------------------------------- 1 | //go:build go1.22 2 | 3 | package rand 4 | 5 | import "math/rand/v2" 6 | 7 | func Shuffle(n int, swap func(i, j int)) { 8 | rand.Shuffle(n, swap) 9 | } 10 | 11 | func IntN(n int) int { 12 | return rand.IntN(n) 13 | } 14 | -------------------------------------------------------------------------------- /vendor/github.com/samber/mo/Dockerfile: -------------------------------------------------------------------------------- 1 | 2 | FROM golang:1.22.5-bullseye 3 | 4 | WORKDIR /go/src/github.com/samber/mo 5 | 6 | COPY Makefile go.* ./ 7 | 8 | RUN make tools 9 | -------------------------------------------------------------------------------- /vendor/github.com/samber/mo/do.go: -------------------------------------------------------------------------------- 1 | package mo 2 | 3 | import ( 4 | "errors" 5 | "fmt" 6 | ) 7 | 8 | // Do executes a function within a monadic context, capturing any errors that occur. 9 | // If the function executes successfully, its result is wrapped in a successful Result. 10 | // If the function panics (indicating a failure), the panic is caught and converted into an error Result. 11 | func Do[T any](fn func() T) (result Result[T]) { 12 | defer func() { 13 | if r := recover(); r != nil { 14 | if err, ok := r.(error); ok { 15 | result = Err[T](err) 16 | } else { 17 | result = Err[T](errors.New(fmt.Sprint(r))) 18 | } 19 | } 20 | }() 21 | return Ok(fn()) 22 | } 23 | -------------------------------------------------------------------------------- /vendor/github.com/samber/mo/option_go122.go: -------------------------------------------------------------------------------- 1 | //go:build go1.22 2 | // +build go1.22 3 | 4 | package mo 5 | 6 | import ( 7 | "database/sql" 8 | "fmt" 9 | ) 10 | 11 | func (o *Option[T]) scanConvertValue(src any) error { 12 | // we try to convertAssign values that we can't directly assign because ConvertValue 13 | // will return immediately for v that is already a Value, even if it is a different 14 | // Value type than the one we expect here. 15 | var st sql.Null[T] 16 | if err := st.Scan(src); err == nil { 17 | o.isPresent = true 18 | o.value = st.V 19 | return nil 20 | } 21 | return fmt.Errorf("failed to scan Option[T]") 22 | } 23 | -------------------------------------------------------------------------------- /vendor/github.com/samber/mo/utils.go: -------------------------------------------------------------------------------- 1 | package mo 2 | 3 | func empty[T any]() (t T) { 4 | return 5 | } 6 | -------------------------------------------------------------------------------- /vendor/github.com/stretchr/testify/assert/assertion_compare_can_convert.go: -------------------------------------------------------------------------------- 1 | //go:build go1.17 2 | // +build go1.17 3 | 4 | // TODO: once support for Go 1.16 is dropped, this file can be 5 | // merged/removed with assertion_compare_go1.17_test.go and 6 | // assertion_compare_legacy.go 7 | 8 | package assert 9 | 10 | import "reflect" 11 | 12 | // Wrapper around reflect.Value.CanConvert, for compatibility 13 | // reasons. 14 | func canConvert(value reflect.Value, to reflect.Type) bool { 15 | return value.CanConvert(to) 16 | } 17 | -------------------------------------------------------------------------------- /vendor/github.com/stretchr/testify/assert/assertion_compare_legacy.go: -------------------------------------------------------------------------------- 1 | //go:build !go1.17 2 | // +build !go1.17 3 | 4 | // TODO: once support for Go 1.16 is dropped, this file can be 5 | // merged/removed with assertion_compare_go1.17_test.go and 6 | // assertion_compare_can_convert.go 7 | 8 | package assert 9 | 10 | import "reflect" 11 | 12 | // Older versions of Go does not have the reflect.Value.CanConvert 13 | // method. 14 | func canConvert(value reflect.Value, to reflect.Type) bool { 15 | return false 16 | } 17 | -------------------------------------------------------------------------------- /vendor/github.com/stretchr/testify/assert/assertion_format.go.tmpl: -------------------------------------------------------------------------------- 1 | {{.CommentFormat}} 2 | func {{.DocInfo.Name}}f(t TestingT, {{.ParamsFormat}}) bool { 3 | if h, ok := t.(tHelper); ok { h.Helper() } 4 | return {{.DocInfo.Name}}(t, {{.ForwardedParamsFormat}}) 5 | } 6 | -------------------------------------------------------------------------------- /vendor/github.com/stretchr/testify/assert/assertion_forward.go.tmpl: -------------------------------------------------------------------------------- 1 | {{.CommentWithoutT "a"}} 2 | func (a *Assertions) {{.DocInfo.Name}}({{.Params}}) bool { 3 | if h, ok := a.t.(tHelper); ok { h.Helper() } 4 | return {{.DocInfo.Name}}(a.t, {{.ForwardedParams}}) 5 | } 6 | -------------------------------------------------------------------------------- /vendor/github.com/stretchr/testify/assert/errors.go: -------------------------------------------------------------------------------- 1 | package assert 2 | 3 | import ( 4 | "errors" 5 | ) 6 | 7 | // AnError is an error instance useful for testing. If the code does not care 8 | // about error specifics, and only needs to return the error for example, this 9 | // error should be used to make the test code more readable. 10 | var AnError = errors.New("assert.AnError general error for testing") 11 | -------------------------------------------------------------------------------- /vendor/github.com/stretchr/testify/assert/forward_assertions.go: -------------------------------------------------------------------------------- 1 | package assert 2 | 3 | // Assertions provides assertion methods around the 4 | // TestingT interface. 5 | type Assertions struct { 6 | t TestingT 7 | } 8 | 9 | // New makes a new Assertions object for the specified TestingT. 10 | func New(t TestingT) *Assertions { 11 | return &Assertions{ 12 | t: t, 13 | } 14 | } 15 | 16 | //go:generate sh -c "cd ../_codegen && go build && cd - && ../_codegen/_codegen -output-package=assert -template=assertion_forward.go.tmpl -include-format-funcs" 17 | -------------------------------------------------------------------------------- /vendor/github.com/stretchr/testify/require/forward_requirements.go: -------------------------------------------------------------------------------- 1 | package require 2 | 3 | // Assertions provides assertion methods around the 4 | // TestingT interface. 5 | type Assertions struct { 6 | t TestingT 7 | } 8 | 9 | // New makes a new Assertions object for the specified TestingT. 10 | func New(t TestingT) *Assertions { 11 | return &Assertions{ 12 | t: t, 13 | } 14 | } 15 | 16 | //go:generate sh -c "cd ../_codegen && go build && cd - && ../_codegen/_codegen -output-package=require -template=require_forward.go.tmpl -include-format-funcs" 17 | -------------------------------------------------------------------------------- /vendor/github.com/stretchr/testify/require/require.go.tmpl: -------------------------------------------------------------------------------- 1 | {{.Comment}} 2 | func {{.DocInfo.Name}}(t TestingT, {{.Params}}) { 3 | if h, ok := t.(tHelper); ok { h.Helper() } 4 | if assert.{{.DocInfo.Name}}(t, {{.ForwardedParams}}) { return } 5 | t.FailNow() 6 | } 7 | -------------------------------------------------------------------------------- /vendor/github.com/stretchr/testify/require/require_forward.go.tmpl: -------------------------------------------------------------------------------- 1 | {{.CommentWithoutT "a"}} 2 | func (a *Assertions) {{.DocInfo.Name}}({{.Params}}) { 3 | if h, ok := a.t.(tHelper); ok { h.Helper() } 4 | {{.DocInfo.Name}}(a.t, {{.ForwardedParams}}) 5 | } 6 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/0_importpath.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2018 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | package codec // import "github.com/ugorji/go/codec" 5 | 6 | // This establishes that this package must be imported as github.com/ugorji/go/codec. 7 | // It makes forking easier, and plays well with pre-module releases of go. 8 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/codecgen.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build codecgen || generated 5 | // +build codecgen generated 6 | 7 | package codec 8 | 9 | // this file sets the codecgen variable to true 10 | // when the build tag codecgen is set. 11 | // 12 | // some tests depend on knowing whether in the context of codecgen or not. 13 | // For example, some tests should be skipped during codecgen e.g. missing fields tests. 14 | 15 | func init() { 16 | codecgen = true 17 | } 18 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/gen-enc-chan.go.tmpl: -------------------------------------------------------------------------------- 1 | {{.Label}}: 2 | switch timeout{{.Sfx}} := z.EncBasicHandle().ChanRecvTimeout; { 3 | case timeout{{.Sfx}} == 0: // only consume available 4 | for { 5 | select { 6 | case b{{.Sfx}} := <-{{.Chan}}: 7 | {{ .Slice }} = append({{.Slice}}, b{{.Sfx}}) 8 | default: 9 | break {{.Label}} 10 | } 11 | } 12 | case timeout{{.Sfx}} > 0: // consume until timeout 13 | tt{{.Sfx}} := time.NewTimer(timeout{{.Sfx}}) 14 | for { 15 | select { 16 | case b{{.Sfx}} := <-{{.Chan}}: 17 | {{.Slice}} = append({{.Slice}}, b{{.Sfx}}) 18 | case <-tt{{.Sfx}}.C: 19 | // close(tt.C) 20 | break {{.Label}} 21 | } 22 | } 23 | default: // consume until close 24 | for b{{.Sfx}} := range {{.Chan}} { 25 | {{.Slice}} = append({{.Slice}}, b{{.Sfx}}) 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_arrayof_gte_go15.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build go1.5 5 | // +build go1.5 6 | 7 | package codec 8 | 9 | import "reflect" 10 | 11 | const reflectArrayOfSupported = true 12 | 13 | func reflectArrayOf(count int, elem reflect.Type) reflect.Type { 14 | return reflect.ArrayOf(count, elem) 15 | } 16 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_arrayof_lt_go15.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build !go1.5 5 | // +build !go1.5 6 | 7 | package codec 8 | 9 | import ( 10 | "errors" 11 | "reflect" 12 | ) 13 | 14 | const reflectArrayOfSupported = false 15 | 16 | var errNoReflectArrayOf = errors.New("codec: reflect.ArrayOf unsupported by this go version") 17 | 18 | func reflectArrayOf(count int, elem reflect.Type) reflect.Type { 19 | panic(errNoReflectArrayOf) 20 | } 21 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_fmt_time_gte_go15.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build go1.5 5 | // +build go1.5 6 | 7 | package codec 8 | 9 | import "time" 10 | 11 | func fmtTime(t time.Time, fmt string, b []byte) []byte { 12 | return t.AppendFormat(b, fmt) 13 | } 14 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_fmt_time_lt_go15.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build !go1.5 5 | // +build !go1.5 6 | 7 | package codec 8 | 9 | import "time" 10 | 11 | func fmtTime(t time.Time, fmt string, b []byte) []byte { 12 | s := t.Format(fmt) 13 | b = b[:len(s)] 14 | copy(b, s) 15 | return b 16 | } 17 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_makemap_lt_go110.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build !go1.10 5 | // +build !go1.10 6 | 7 | package codec 8 | 9 | import "reflect" 10 | 11 | func makeMapReflect(t reflect.Type, size int) reflect.Value { 12 | return reflect.MakeMap(t) 13 | } 14 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_makemap_not_unsafe_gte_go110.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build go1.10 && (safe || codec.safe || appengine) 5 | // +build go1.10 6 | // +build safe codec.safe appengine 7 | 8 | package codec 9 | 10 | import "reflect" 11 | 12 | func makeMapReflect(t reflect.Type, size int) reflect.Value { 13 | return reflect.MakeMapWithSize(t, size) 14 | } 15 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_makemap_unsafe_gte_go110.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build go1.10 && !safe && !codec.safe && !appengine 5 | // +build go1.10,!safe,!codec.safe,!appengine 6 | 7 | package codec 8 | 9 | import ( 10 | "reflect" 11 | "unsafe" 12 | ) 13 | 14 | func makeMapReflect(typ reflect.Type, size int) (rv reflect.Value) { 15 | t := (*unsafeIntf)(unsafe.Pointer(&typ)).ptr 16 | urv := (*unsafeReflectValue)(unsafe.Pointer(&rv)) 17 | urv.typ = t 18 | urv.flag = uintptr(reflect.Map) 19 | urv.ptr = makemap(t, size, nil) 20 | return 21 | } 22 | 23 | //go:linkname makemap runtime.makemap 24 | //go:noescape 25 | func makemap(typ unsafe.Pointer, size int, h unsafe.Pointer) unsafe.Pointer 26 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_unexportedembeddedptr_gte_go110.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build go1.10 5 | // +build go1.10 6 | 7 | package codec 8 | 9 | const allowSetUnexportedEmbeddedPtr = false 10 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_unexportedembeddedptr_lt_go110.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build !go1.10 5 | // +build !go1.10 6 | 7 | package codec 8 | 9 | const allowSetUnexportedEmbeddedPtr = true 10 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_unsupported_lt_go14.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build !go1.4 5 | // +build !go1.4 6 | 7 | package codec 8 | 9 | import "errors" 10 | 11 | // This codec package will only work for go1.4 and above. 12 | // This is for the following reasons: 13 | // - go 1.4 was released in 2014 14 | // - go runtime is written fully in go 15 | // - interface only holds pointers 16 | // - reflect.Value is stabilized as 3 words 17 | 18 | var errCodecSupportedOnlyFromGo14 = errors.New("codec: go 1.3 and below are not supported") 19 | 20 | func init() { 21 | panic(errCodecSupportedOnlyFromGo14) 22 | } 23 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_vendor_eq_go15.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build go1.5 && !go1.6 5 | // +build go1.5,!go1.6 6 | 7 | package codec 8 | 9 | import "os" 10 | 11 | var genCheckVendor = os.Getenv("GO15VENDOREXPERIMENT") == "1" 12 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_vendor_eq_go16.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build go1.6 && !go1.7 5 | // +build go1.6,!go1.7 6 | 7 | package codec 8 | 9 | import "os" 10 | 11 | var genCheckVendor = os.Getenv("GO15VENDOREXPERIMENT") != "0" 12 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_vendor_gte_go17.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build go1.7 5 | // +build go1.7 6 | 7 | package codec 8 | 9 | const genCheckVendor = true 10 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/goversion_vendor_lt_go15.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build !go1.5 5 | // +build !go1.5 6 | 7 | package codec 8 | 9 | var genCheckVendor = false 10 | -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/helper.s: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/ugorji/go/codec/helper.s -------------------------------------------------------------------------------- /vendor/github.com/ugorji/go/codec/helper_not_unsafe_not_gc.go: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2012-2020 Ugorji Nwoke. All rights reserved. 2 | // Use of this source code is governed by a MIT license found in the LICENSE file. 3 | 4 | //go:build !go1.9 || safe || codec.safe || appengine || !gc 5 | // +build !go1.9 safe codec.safe appengine !gc 6 | 7 | package codec 8 | 9 | import "reflect" 10 | 11 | // This files contains safe versions of the code where the unsafe versions are not supported 12 | // in either gccgo or gollvm. 13 | // 14 | // - rvType: 15 | // reflect.toType is not supported in gccgo, gollvm. 16 | 17 | func rvType(rv reflect.Value) reflect.Type { 18 | return rv.Type() 19 | } 20 | -------------------------------------------------------------------------------- /vendor/github.com/urfave/cli/.flake8: -------------------------------------------------------------------------------- 1 | [flake8] 2 | max-line-length = 120 3 | -------------------------------------------------------------------------------- /vendor/github.com/urfave/cli/.gitignore: -------------------------------------------------------------------------------- 1 | *.coverprofile 2 | coverage.txt 3 | node_modules/ 4 | vendor 5 | .idea 6 | -------------------------------------------------------------------------------- /vendor/github.com/urfave/cli/altsrc/input_source_context.go: -------------------------------------------------------------------------------- 1 | package altsrc 2 | 3 | import ( 4 | "time" 5 | 6 | "github.com/urfave/cli" 7 | ) 8 | 9 | // InputSourceContext is an interface used to allow 10 | // other input sources to be implemented as needed. 11 | type InputSourceContext interface { 12 | Int(name string) (int, error) 13 | Duration(name string) (time.Duration, error) 14 | Float64(name string) (float64, error) 15 | String(name string) (string, error) 16 | StringSlice(name string) ([]string, error) 17 | IntSlice(name string) ([]int, error) 18 | Generic(name string) (cli.Generic, error) 19 | Bool(name string) (bool, error) 20 | BoolT(name string) (bool, error) 21 | } 22 | -------------------------------------------------------------------------------- /vendor/github.com/urfave/cli/appveyor.yml: -------------------------------------------------------------------------------- 1 | version: "{build}" 2 | 3 | os: Windows Server 2016 4 | 5 | image: Visual Studio 2017 6 | 7 | clone_folder: c:\gopath\src\github.com\urfave\cli 8 | 9 | cache: 10 | - node_modules 11 | 12 | environment: 13 | GOPATH: C:\gopath 14 | GOVERSION: 1.11.x 15 | GO111MODULE: on 16 | GOPROXY: https://proxy.golang.org 17 | 18 | install: 19 | - set PATH=%GOPATH%\bin;C:\go\bin;%PATH% 20 | - go version 21 | - go env 22 | - go get github.com/urfave/gfmrun/cmd/gfmrun 23 | - go mod vendor 24 | 25 | build_script: 26 | - go run build.go vet 27 | - go run build.go test 28 | - go run build.go gfmrun docs/v1/manual.md 29 | -------------------------------------------------------------------------------- /vendor/github.com/urfave/cli/cli.go: -------------------------------------------------------------------------------- 1 | // Package cli provides a minimal framework for creating and organizing command line 2 | // Go applications. cli is designed to be easy to understand and write, the most simple 3 | // cli application can be written as follows: 4 | // func main() { 5 | // cli.NewApp().Run(os.Args) 6 | // } 7 | // 8 | // Of course this application does not do much, so let's make this an actual application: 9 | // func main() { 10 | // app := cli.NewApp() 11 | // app.Name = "greet" 12 | // app.Usage = "say a greeting" 13 | // app.Action = func(c *cli.Context) error { 14 | // println("Greetings") 15 | // return nil 16 | // } 17 | // 18 | // app.Run(os.Args) 19 | // } 20 | package cli 21 | 22 | //go:generate go run flag-gen/main.go flag-gen/assets_vfsdata.go 23 | -------------------------------------------------------------------------------- /vendor/github.com/urfave/cli/sort.go: -------------------------------------------------------------------------------- 1 | package cli 2 | 3 | import "unicode" 4 | 5 | // lexicographicLess compares strings alphabetically considering case. 6 | func lexicographicLess(i, j string) bool { 7 | iRunes := []rune(i) 8 | jRunes := []rune(j) 9 | 10 | lenShared := len(iRunes) 11 | if lenShared > len(jRunes) { 12 | lenShared = len(jRunes) 13 | } 14 | 15 | for index := 0; index < lenShared; index++ { 16 | ir := iRunes[index] 17 | jr := jRunes[index] 18 | 19 | if lir, ljr := unicode.ToLower(ir), unicode.ToLower(jr); lir != ljr { 20 | return lir < ljr 21 | } 22 | 23 | if ir != jr { 24 | return ir < jr 25 | } 26 | } 27 | 28 | return i < j 29 | } 30 | -------------------------------------------------------------------------------- /vendor/github.com/xdg-go/pbkdf2/.gitignore: -------------------------------------------------------------------------------- 1 | # Binaries for programs and plugins 2 | *.exe 3 | *.exe~ 4 | *.dll 5 | *.so 6 | *.dylib 7 | 8 | # Test binary, build with `go test -c` 9 | *.test 10 | 11 | # Output of the go coverage tool, specifically when used with LiteIDE 12 | *.out 13 | -------------------------------------------------------------------------------- /vendor/github.com/xdg-go/scram/.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/xdg-go/scram/.gitignore -------------------------------------------------------------------------------- /vendor/github.com/xdg-go/scram/CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # CHANGELOG 2 | 3 | ## v1.1.2 - 2022-12-07 4 | 5 | - Bump stringprep dependency to v1.0.4 for upstream CVE fix. 6 | 7 | ## v1.1.1 - 2022-03-03 8 | 9 | - Bump stringprep dependency to v1.0.3 for upstream CVE fix. 10 | 11 | ## v1.1.0 - 2022-01-16 12 | 13 | - Add SHA-512 hash generator function for convenience. 14 | 15 | ## v1.0.2 - 2021-03-28 16 | 17 | - Switch PBKDF2 dependency to github.com/xdg-go/pbkdf2 to 18 | minimize transitive dependencies and support Go 1.9+. 19 | 20 | ## v1.0.1 - 2021-03-27 21 | 22 | - Bump stringprep dependency to v1.0.2 for Go 1.11 support. 23 | 24 | ## v1.0.0 - 2021-03-27 25 | 26 | - First release as a Go module 27 | -------------------------------------------------------------------------------- /vendor/github.com/xdg-go/stringprep/.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mongodb-labs/migration-verifier/d7b456ec4a28b253463edf8882a535ba986d2b6d/vendor/github.com/xdg-go/stringprep/.gitignore -------------------------------------------------------------------------------- /vendor/github.com/xdg-go/stringprep/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 by David A. Golden. All rights reserved. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | // Package stringprep provides data tables and algorithms for RFC-3454, 8 | // including errata (as of 2018-02). It also provides a profile for 9 | // SASLprep as defined in RFC-4013. 10 | package stringprep 11 | -------------------------------------------------------------------------------- /vendor/github.com/xdg-go/stringprep/error.go: -------------------------------------------------------------------------------- 1 | package stringprep 2 | 3 | import "fmt" 4 | 5 | // Error describes problems encountered during stringprep, including what rune 6 | // was problematic. 7 | type Error struct { 8 | Msg string 9 | Rune rune 10 | } 11 | 12 | func (e Error) Error() string { 13 | return fmt.Sprintf("%s (rune: '\\u%04x')", e.Msg, e.Rune) 14 | } 15 | -------------------------------------------------------------------------------- /vendor/github.com/xdg-go/stringprep/map.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 by David A. Golden. All rights reserved. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | package stringprep 8 | 9 | // Mapping represents a stringprep mapping, from a single rune to zero or more 10 | // runes. 11 | type Mapping map[rune][]rune 12 | 13 | // Map maps a rune to a (possibly empty) rune slice via a stringprep Mapping. 14 | // The ok return value is false if the rune was not found. 15 | func (m Mapping) Map(r rune) (replacement []rune, ok bool) { 16 | rs, ok := m[r] 17 | if !ok { 18 | return nil, false 19 | } 20 | return rs, true 21 | } 22 | -------------------------------------------------------------------------------- /vendor/github.com/youmark/pkcs8/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | 10 | # Architecture specific extensions/prefixes 11 | *.[568vq] 12 | [568vq].out 13 | 14 | *.cgo1.go 15 | *.cgo2.c 16 | _cgo_defun.c 17 | _cgo_gotypes.go 18 | _cgo_export.* 19 | 20 | _testmain.go 21 | 22 | *.exe 23 | *.test 24 | -------------------------------------------------------------------------------- /vendor/github.com/youmark/pkcs8/README: -------------------------------------------------------------------------------- 1 | pkcs8 package: implement PKCS#8 private key parsing and conversion as defined in RFC5208 and RFC5958 2 | -------------------------------------------------------------------------------- /vendor/github.com/youmark/pkcs8/cipher_3des.go: -------------------------------------------------------------------------------- 1 | package pkcs8 2 | 3 | import ( 4 | "crypto/des" 5 | "encoding/asn1" 6 | ) 7 | 8 | var ( 9 | oidDESEDE3CBC = asn1.ObjectIdentifier{1, 2, 840, 113549, 3, 7} 10 | ) 11 | 12 | func init() { 13 | RegisterCipher(oidDESEDE3CBC, func() Cipher { 14 | return TripleDESCBC 15 | }) 16 | } 17 | 18 | // TripleDESCBC is the 168-bit key 3DES cipher in CBC mode. 19 | var TripleDESCBC = cipherWithBlock{ 20 | ivSize: des.BlockSize, 21 | keySize: 24, 22 | newBlock: des.NewTripleDESCipher, 23 | oid: oidDESEDE3CBC, 24 | } 25 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/bson/bsoncodec/proxy.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | package bsoncodec 8 | 9 | // Proxy is an interface implemented by types that cannot themselves be directly encoded. Types 10 | // that implement this interface with have ProxyBSON called during the encoding process and that 11 | // value will be encoded in place for the implementer. 12 | type Proxy interface { 13 | ProxyBSON() (interface{}, error) 14 | } 15 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/bson/bsonoptions/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2022-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | // Package bsonoptions defines the optional configurations for the BSON codecs. 8 | package bsonoptions 9 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/bson/bsonrw/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | // Package bsonrw contains abstractions for reading and writing 8 | // BSON and BSON like types from sources. 9 | package bsonrw // import "go.mongodb.org/mongo-driver/bson/bsonrw" 10 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/internal/handshake/handshake.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | package handshake 8 | 9 | // LegacyHello is the legacy version of the hello command. 10 | var LegacyHello = "isMaster" 11 | 12 | // LegacyHelloLowercase is the lowercase, legacy version of the hello command. 13 | var LegacyHelloLowercase = "ismaster" 14 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/mongo/description/description.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | // Package description contains types and functions for describing the state of MongoDB clusters. 8 | package description // import "go.mongodb.org/mongo-driver/mongo/description" 9 | 10 | // Unknown is an unknown server or topology kind. 11 | const Unknown = 0 12 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/mongo/options/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2022-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | // Package options defines the optional configurations for the MongoDB Go Driver. 8 | package options 9 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/mongo/util.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | package mongo 8 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/version/version.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | // Package version defines the Go Driver version. 8 | package version // import "go.mongodb.org/mongo-driver/version" 9 | 10 | // Driver is the current version of the driver. 11 | var Driver = "1.17.1" 12 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/auth/cred.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | package auth 8 | 9 | import ( 10 | "go.mongodb.org/mongo-driver/x/mongo/driver" 11 | ) 12 | 13 | // Cred is the type of user credential 14 | type Cred = driver.Cred 15 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/auth/creds/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2024-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | // Package creds is intended for internal use only. It is made available to 8 | // facilitate use cases that require access to internal MongoDB driver 9 | // functionality and state. The API of this package is not stable and there is 10 | // no backward compatibility guarantee. 11 | // 12 | // WARNING: THIS PACKAGE IS EXPERIMENTAL AND MAY BE MODIFIED OR REMOVED WITHOUT 13 | // NOTICE! USE WITH EXTREME CAUTION! 14 | package creds 15 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/auth/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | // Package auth is intended for internal use only. It is made available to 8 | // facilitate use cases that require access to internal MongoDB driver 9 | // functionality and state. The API of this package is not stable and there is 10 | // no backward compatibility guarantee. 11 | // 12 | // WARNING: THIS PACKAGE IS EXPERIMENTAL AND MAY BE MODIFIED OR REMOVED WITHOUT 13 | // NOTICE! USE WITH EXTREME CAUTION! 14 | package auth 15 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/auth/gssapi_not_enabled.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | //go:build !gssapi 8 | // +build !gssapi 9 | 10 | package auth 11 | 12 | import "net/http" 13 | 14 | // GSSAPI is the mechanism name for GSSAPI. 15 | const GSSAPI = "GSSAPI" 16 | 17 | func newGSSAPIAuthenticator(*Cred, *http.Client) (Authenticator, error) { 18 | return nil, newAuthError("GSSAPI support not enabled during build (-tags gssapi)", nil) 19 | } 20 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/auth/gssapi_not_supported.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | //go:build gssapi && !windows && !linux && !darwin 8 | // +build gssapi,!windows,!linux,!darwin 9 | 10 | package auth 11 | 12 | import ( 13 | "fmt" 14 | "net/http" 15 | "runtime" 16 | ) 17 | 18 | // GSSAPI is the mechanism name for GSSAPI. 19 | const GSSAPI = "GSSAPI" 20 | 21 | func newGSSAPIAuthenticator(*Cred, *http.Client) (Authenticator, error) { 22 | return nil, newAuthError(fmt.Sprintf("GSSAPI is not supported on %s", runtime.GOOS), nil) 23 | } 24 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/mongocrypt/errors_not_enabled.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | //go:build !cse 8 | // +build !cse 9 | 10 | package mongocrypt 11 | 12 | // Error represents an error from an operation on a MongoCrypt instance. 13 | type Error struct { 14 | Code int32 15 | Message string 16 | } 17 | 18 | // Error implements the error interface 19 | func (Error) Error() string { 20 | panic(cseNotSupportedMsg) 21 | } 22 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/mongocrypt/options/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2024-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | // Package options is intended for internal use only. It is made available to 8 | // facilitate use cases that require access to internal MongoDB driver 9 | // functionality and state. The API of this package is not stable and there is 10 | // no backward compatibility guarantee. 11 | // 12 | // WARNING: THIS PACKAGE IS EXPERIMENTAL AND MAY BE MODIFIED OR REMOVED WITHOUT 13 | // NOTICE! USE WITH EXTREME CAUTION! 14 | package options 15 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/ocsp/options.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | package ocsp 8 | 9 | import "net/http" 10 | 11 | // VerifyOptions specifies options to configure OCSP verification. 12 | type VerifyOptions struct { 13 | Cache Cache 14 | DisableEndpointChecking bool 15 | HTTPClient *http.Client 16 | } 17 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/operation/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2024-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | // Package operation is intended for internal use only. It is made available to 8 | // facilitate use cases that require access to internal MongoDB driver 9 | // functionality and state. The API of this package is not stable and there is 10 | // no backward compatibility guarantee. 11 | // 12 | // WARNING: THIS PACKAGE IS EXPERIMENTAL AND MAY BE MODIFIED OR REMOVED WITHOUT 13 | // NOTICE! USE WITH EXTREME CAUTION! 14 | package operation 15 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/operation/errors.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | package operation 8 | 9 | import "errors" 10 | 11 | var ( 12 | errUnacknowledgedHint = errors.New("the 'hint' command parameter cannot be used with unacknowledged writes") 13 | ) 14 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/session/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2024-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | // Package session is intended for internal use only. It is made available to 8 | // facilitate use cases that require access to internal MongoDB driver 9 | // functionality and state. The API of this package is not stable and there is 10 | // no backward compatibility guarantee. 11 | // 12 | // WARNING: THIS PACKAGE IS EXPERIMENTAL AND MAY BE MODIFIED OR REMOVED WITHOUT 13 | // NOTICE! USE WITH EXTREME CAUTION! 14 | package session 15 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/topology/cancellation_listener.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2017-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | package topology 8 | 9 | import "context" 10 | 11 | type cancellationListener interface { 12 | Listen(context.Context, func()) 13 | StopListening() bool 14 | } 15 | -------------------------------------------------------------------------------- /vendor/go.mongodb.org/mongo-driver/x/mongo/driver/topology/connection_legacy.go: -------------------------------------------------------------------------------- 1 | // Copyright (C) MongoDB, Inc. 2022-present. 2 | // 3 | // Licensed under the Apache License, Version 2.0 (the "License"); you may 4 | // not use this file except in compliance with the License. You may obtain 5 | // a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 6 | 7 | package topology 8 | -------------------------------------------------------------------------------- /vendor/golang.org/x/crypto/sha3/hashes_noasm.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !gc || purego || !s390x 6 | 7 | package sha3 8 | 9 | func new224() *state { 10 | return new224Generic() 11 | } 12 | 13 | func new256() *state { 14 | return new256Generic() 15 | } 16 | 17 | func new384() *state { 18 | return new384Generic() 19 | } 20 | 21 | func new512() *state { 22 | return new512Generic() 23 | } 24 | -------------------------------------------------------------------------------- /vendor/golang.org/x/crypto/sha3/keccakf_amd64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build amd64 && !purego && gc 6 | 7 | package sha3 8 | 9 | // This function is implemented in keccakf_amd64.s. 10 | 11 | //go:noescape 12 | 13 | func keccakF1600(a *[25]uint64) 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/crypto/sha3/shake_noasm.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !gc || purego || !s390x 6 | 7 | package sha3 8 | 9 | func newShake128() *state { 10 | return newShake128Generic() 11 | } 12 | 13 | func newShake256() *state { 14 | return newShake256Generic() 15 | } 16 | -------------------------------------------------------------------------------- /vendor/golang.org/x/net/http2/.gitignore: -------------------------------------------------------------------------------- 1 | *~ 2 | h2i/h2i 3 | -------------------------------------------------------------------------------- /vendor/golang.org/x/net/idna/go118.go: -------------------------------------------------------------------------------- 1 | // Code generated by running "go generate" in golang.org/x/text. DO NOT EDIT. 2 | 3 | // Copyright 2021 The Go Authors. All rights reserved. 4 | // Use of this source code is governed by a BSD-style 5 | // license that can be found in the LICENSE file. 6 | 7 | //go:build go1.18 8 | 9 | package idna 10 | 11 | // Transitional processing is disabled by default in Go 1.18. 12 | // https://golang.org/issue/47510 13 | const transitionalLookup = false 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/net/idna/pre_go118.go: -------------------------------------------------------------------------------- 1 | // Code generated by running "go generate" in golang.org/x/text. DO NOT EDIT. 2 | 3 | // Copyright 2021 The Go Authors. All rights reserved. 4 | // Use of this source code is governed by a BSD-style 5 | // license that can be found in the LICENSE file. 6 | 7 | //go:build !go1.18 8 | 9 | package idna 10 | 11 | const transitionalLookup = true 12 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sync/errgroup/go120.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build go1.20 6 | 7 | package errgroup 8 | 9 | import "context" 10 | 11 | func withCancelCause(parent context.Context) (context.Context, func(error)) { 12 | return context.WithCancelCause(parent) 13 | } 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sync/errgroup/pre_go120.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !go1.20 6 | 7 | package errgroup 8 | 9 | import "context" 10 | 11 | func withCancelCause(parent context.Context) (context.Context, func(error)) { 12 | ctx, cancel := context.WithCancel(parent) 13 | return ctx, func(error) { cancel() } 14 | } 15 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/asm_aix_ppc64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build gc 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System calls for ppc64, AIX are implemented in runtime/syscall_aix.go 11 | // 12 | 13 | TEXT ·syscall6(SB),NOSPLIT,$0-88 14 | JMP syscall·syscall6(SB) 15 | 16 | TEXT ·rawSyscall6(SB),NOSPLIT,$0-88 17 | JMP syscall·rawSyscall6(SB) 18 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_aix.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix 6 | 7 | package cpu 8 | 9 | const ( 10 | // getsystemcfg constants 11 | _SC_IMPL = 2 12 | _IMPL_POWER8 = 0x10000 13 | _IMPL_POWER9 = 0x20000 14 | ) 15 | 16 | func archInit() { 17 | impl := getsystemcfg(_SC_IMPL) 18 | if impl&_IMPL_POWER8 != 0 { 19 | PPC64.IsPOWER8 = true 20 | } 21 | if impl&_IMPL_POWER9 != 0 { 22 | PPC64.IsPOWER8 = true 23 | PPC64.IsPOWER9 = true 24 | } 25 | 26 | Initialized = true 27 | } 28 | 29 | func getsystemcfg(label int) (n uint64) { 30 | r0, _ := callgetsystemcfg(label) 31 | n = uint64(r0) 32 | return 33 | } 34 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_gc_arm64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build gc 6 | 7 | package cpu 8 | 9 | func getisar0() uint64 10 | func getisar1() uint64 11 | func getpfr0() uint64 12 | func getzfr0() uint64 13 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_gc_s390x.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build gc 6 | 7 | package cpu 8 | 9 | // haveAsmFunctions reports whether the other functions in this file can 10 | // be safely called. 11 | func haveAsmFunctions() bool { return true } 12 | 13 | // The following feature detection functions are defined in cpu_s390x.s. 14 | // They are likely to be expensive to call so the results should be cached. 15 | func stfle() facilityList 16 | func kmQuery() queryResult 17 | func kmcQuery() queryResult 18 | func kmctrQuery() queryResult 19 | func kmaQuery() queryResult 20 | func kimdQuery() queryResult 21 | func klmdQuery() queryResult 22 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_gc_x86.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (386 || amd64 || amd64p32) && gc 6 | 7 | package cpu 8 | 9 | // cpuid is implemented in cpu_x86.s for gc compiler 10 | // and in cpu_gccgo.c for gccgo. 11 | func cpuid(eaxArg, ecxArg uint32) (eax, ebx, ecx, edx uint32) 12 | 13 | // xgetbv with ecx = 0 is implemented in cpu_x86.s for gc compiler 14 | // and in cpu_gccgo.c for gccgo. 15 | func xgetbv() (eax, edx uint32) 16 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_gccgo_arm64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build gccgo 6 | 7 | package cpu 8 | 9 | func getisar0() uint64 { return 0 } 10 | func getisar1() uint64 { return 0 } 11 | func getpfr0() uint64 { return 0 } 12 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_linux.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !386 && !amd64 && !amd64p32 && !arm64 6 | 7 | package cpu 8 | 9 | func archInit() { 10 | if err := readHWCAP(); err != nil { 11 | return 12 | } 13 | doinit() 14 | Initialized = true 15 | } 16 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_linux_mips64x.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build linux && (mips64 || mips64le) 6 | 7 | package cpu 8 | 9 | // HWCAP bits. These are exposed by the Linux kernel 5.4. 10 | const ( 11 | // CPU features 12 | hwcap_MIPS_MSA = 1 << 1 13 | ) 14 | 15 | func doinit() { 16 | // HWCAP feature bits 17 | MIPS64X.HasMSA = isSet(hwCap, hwcap_MIPS_MSA) 18 | } 19 | 20 | func isSet(hwc uint, value uint) bool { 21 | return hwc&value != 0 22 | } 23 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_linux_noinit.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build linux && !arm && !arm64 && !mips64 && !mips64le && !ppc64 && !ppc64le && !s390x 6 | 7 | package cpu 8 | 9 | func doinit() {} 10 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_loong64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build loong64 6 | 7 | package cpu 8 | 9 | const cacheLineSize = 64 10 | 11 | func initOptions() { 12 | } 13 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_mips64x.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build mips64 || mips64le 6 | 7 | package cpu 8 | 9 | const cacheLineSize = 32 10 | 11 | func initOptions() { 12 | options = []option{ 13 | {Name: "msa", Feature: &MIPS64X.HasMSA}, 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_mipsx.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build mips || mipsle 6 | 7 | package cpu 8 | 9 | const cacheLineSize = 32 10 | 11 | func initOptions() {} 12 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_openbsd_arm64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | #include "textflag.h" 6 | 7 | TEXT libc_sysctl_trampoline<>(SB),NOSPLIT,$0-0 8 | JMP libc_sysctl(SB) 9 | 10 | GLOBL ·libc_sysctl_trampoline_addr(SB), RODATA, $8 11 | DATA ·libc_sysctl_trampoline_addr(SB)/8, $libc_sysctl_trampoline<>(SB) 12 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_other_arm.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !linux && arm 6 | 7 | package cpu 8 | 9 | func archInit() {} 10 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_other_arm64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !linux && !netbsd && !openbsd && arm64 6 | 7 | package cpu 8 | 9 | func doinit() {} 10 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_other_mips64x.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !linux && (mips64 || mips64le) 6 | 7 | package cpu 8 | 9 | func archInit() { 10 | Initialized = true 11 | } 12 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_other_ppc64x.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !aix && !linux && (ppc64 || ppc64le) 6 | 7 | package cpu 8 | 9 | func archInit() { 10 | PPC64.IsPOWER8 = true 11 | Initialized = true 12 | } 13 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_other_riscv64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !linux && riscv64 6 | 7 | package cpu 8 | 9 | func archInit() { 10 | Initialized = true 11 | } 12 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_ppc64x.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build ppc64 || ppc64le 6 | 7 | package cpu 8 | 9 | const cacheLineSize = 128 10 | 11 | func initOptions() { 12 | options = []option{ 13 | {Name: "darn", Feature: &PPC64.HasDARN}, 14 | {Name: "scv", Feature: &PPC64.HasSCV}, 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_riscv64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build riscv64 6 | 7 | package cpu 8 | 9 | const cacheLineSize = 64 10 | 11 | func initOptions() {} 12 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_wasm.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build wasm 6 | 7 | package cpu 8 | 9 | // We're compiling the cpu package for an unknown (software-abstracted) CPU. 10 | // Make CacheLinePad an empty struct and hope that the usual struct alignment 11 | // rules are good enough. 12 | 13 | const cacheLineSize = 0 14 | 15 | func initOptions() {} 16 | 17 | func archInit() {} 18 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_x86.s: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (386 || amd64 || amd64p32) && gc 6 | 7 | #include "textflag.h" 8 | 9 | // func cpuid(eaxArg, ecxArg uint32) (eax, ebx, ecx, edx uint32) 10 | TEXT ·cpuid(SB), NOSPLIT, $0-24 11 | MOVL eaxArg+0(FP), AX 12 | MOVL ecxArg+4(FP), CX 13 | CPUID 14 | MOVL AX, eax+8(FP) 15 | MOVL BX, ebx+12(FP) 16 | MOVL CX, ecx+16(FP) 17 | MOVL DX, edx+20(FP) 18 | RET 19 | 20 | // func xgetbv() (eax, edx uint32) 21 | TEXT ·xgetbv(SB),NOSPLIT,$0-8 22 | MOVL $0, CX 23 | XGETBV 24 | MOVL AX, eax+0(FP) 25 | MOVL DX, edx+4(FP) 26 | RET 27 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_zos.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package cpu 6 | 7 | func archInit() { 8 | doinit() 9 | Initialized = true 10 | } 11 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/cpu_zos_s390x.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package cpu 6 | 7 | func initS390Xbase() { 8 | // get the facilities list 9 | facilities := stfle() 10 | 11 | // mandatory 12 | S390X.HasZARCH = facilities.Has(zarch) 13 | S390X.HasSTFLE = facilities.Has(stflef) 14 | S390X.HasLDISP = facilities.Has(ldisp) 15 | S390X.HasEIMM = facilities.Has(eimm) 16 | 17 | // optional 18 | S390X.HasETF3EH = facilities.Has(etf3eh) 19 | S390X.HasDFP = facilities.Has(dfp) 20 | S390X.HasMSA = facilities.Has(msa) 21 | S390X.HasVX = facilities.Has(vx) 22 | if S390X.HasVX { 23 | S390X.HasVXE = facilities.Has(vxe) 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/endian_big.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build armbe || arm64be || m68k || mips || mips64 || mips64p32 || ppc || ppc64 || s390 || s390x || shbe || sparc || sparc64 6 | 7 | package cpu 8 | 9 | // IsBigEndian records whether the GOARCH's byte order is big endian. 10 | const IsBigEndian = true 11 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/endian_little.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build 386 || amd64 || amd64p32 || alpha || arm || arm64 || loong64 || mipsle || mips64le || mips64p32le || nios2 || ppc64le || riscv || riscv64 || sh || wasm 6 | 7 | package cpu 8 | 9 | // IsBigEndian records whether the GOARCH's byte order is big endian. 10 | const IsBigEndian = false 11 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/runtime_auxv.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package cpu 6 | 7 | // getAuxvFn is non-nil on Go 1.21+ (via runtime_auxv_go121.go init) 8 | // on platforms that use auxv. 9 | var getAuxvFn func() []uintptr 10 | 11 | func getAuxv() []uintptr { 12 | if getAuxvFn == nil { 13 | return nil 14 | } 15 | return getAuxvFn() 16 | } 17 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/runtime_auxv_go121.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build go1.21 6 | 7 | package cpu 8 | 9 | import ( 10 | _ "unsafe" // for linkname 11 | ) 12 | 13 | //go:linkname runtime_getAuxv runtime.getAuxv 14 | func runtime_getAuxv() []uintptr 15 | 16 | func init() { 17 | getAuxvFn = runtime_getAuxv 18 | } 19 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/cpu/syscall_aix_gccgo.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Recreate a getsystemcfg syscall handler instead of 6 | // using the one provided by x/sys/unix to avoid having 7 | // the dependency between them. (See golang.org/issue/32102) 8 | // Moreover, this file will be used during the building of 9 | // gccgo's libgo and thus must not used a CGo method. 10 | 11 | //go:build aix && gccgo 12 | 13 | package cpu 14 | 15 | import ( 16 | "syscall" 17 | ) 18 | 19 | //extern getsystemcfg 20 | func gccgoGetsystemcfg(label uint32) (r uint64) 21 | 22 | func callgetsystemcfg(label int) (r1 uintptr, e1 syscall.Errno) { 23 | r1 = uintptr(gccgoGetsystemcfg(uint32(label))) 24 | e1 = syscall.GetErrno() 25 | return 26 | } 27 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/.gitignore: -------------------------------------------------------------------------------- 1 | _obj/ 2 | unix.test 3 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/aliases.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris || zos 6 | 7 | package unix 8 | 9 | import "syscall" 10 | 11 | type Signal = syscall.Signal 12 | type Errno = syscall.Errno 13 | type SysProcAttr = syscall.SysProcAttr 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_aix_ppc64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build gc 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System calls for ppc64, AIX are implemented in runtime/syscall_aix.go 11 | // 12 | 13 | TEXT ·syscall6(SB),NOSPLIT,$0-88 14 | JMP syscall·syscall6(SB) 15 | 16 | TEXT ·rawSyscall6(SB),NOSPLIT,$0-88 17 | JMP syscall·rawSyscall6(SB) 18 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_bsd_386.s: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (freebsd || netbsd || openbsd) && gc 6 | 7 | #include "textflag.h" 8 | 9 | // System call support for 386 BSD 10 | 11 | // Just jump to package syscall's implementation for all these functions. 12 | // The runtime may know about them. 13 | 14 | TEXT ·Syscall(SB),NOSPLIT,$0-28 15 | JMP syscall·Syscall(SB) 16 | 17 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 18 | JMP syscall·Syscall6(SB) 19 | 20 | TEXT ·Syscall9(SB),NOSPLIT,$0-52 21 | JMP syscall·Syscall9(SB) 22 | 23 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 24 | JMP syscall·RawSyscall(SB) 25 | 26 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 27 | JMP syscall·RawSyscall6(SB) 28 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_bsd_amd64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (darwin || dragonfly || freebsd || netbsd || openbsd) && gc 6 | 7 | #include "textflag.h" 8 | 9 | // System call support for AMD64 BSD 10 | 11 | // Just jump to package syscall's implementation for all these functions. 12 | // The runtime may know about them. 13 | 14 | TEXT ·Syscall(SB),NOSPLIT,$0-56 15 | JMP syscall·Syscall(SB) 16 | 17 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 18 | JMP syscall·Syscall6(SB) 19 | 20 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 21 | JMP syscall·Syscall9(SB) 22 | 23 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 24 | JMP syscall·RawSyscall(SB) 25 | 26 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 27 | JMP syscall·RawSyscall6(SB) 28 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_bsd_arm.s: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (freebsd || netbsd || openbsd) && gc 6 | 7 | #include "textflag.h" 8 | 9 | // System call support for ARM BSD 10 | 11 | // Just jump to package syscall's implementation for all these functions. 12 | // The runtime may know about them. 13 | 14 | TEXT ·Syscall(SB),NOSPLIT,$0-28 15 | B syscall·Syscall(SB) 16 | 17 | TEXT ·Syscall6(SB),NOSPLIT,$0-40 18 | B syscall·Syscall6(SB) 19 | 20 | TEXT ·Syscall9(SB),NOSPLIT,$0-52 21 | B syscall·Syscall9(SB) 22 | 23 | TEXT ·RawSyscall(SB),NOSPLIT,$0-28 24 | B syscall·RawSyscall(SB) 25 | 26 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-40 27 | B syscall·RawSyscall6(SB) 28 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_bsd_arm64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (darwin || freebsd || netbsd || openbsd) && gc 6 | 7 | #include "textflag.h" 8 | 9 | // System call support for ARM64 BSD 10 | 11 | // Just jump to package syscall's implementation for all these functions. 12 | // The runtime may know about them. 13 | 14 | TEXT ·Syscall(SB),NOSPLIT,$0-56 15 | JMP syscall·Syscall(SB) 16 | 17 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 18 | JMP syscall·Syscall6(SB) 19 | 20 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 21 | JMP syscall·Syscall9(SB) 22 | 23 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 24 | JMP syscall·RawSyscall(SB) 25 | 26 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 27 | JMP syscall·RawSyscall6(SB) 28 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_bsd_ppc64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (darwin || freebsd || netbsd || openbsd) && gc 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for ppc64, BSD 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-56 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_bsd_riscv64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (darwin || freebsd || netbsd || openbsd) && gc 6 | 7 | #include "textflag.h" 8 | 9 | // System call support for RISCV64 BSD 10 | 11 | // Just jump to package syscall's implementation for all these functions. 12 | // The runtime may know about them. 13 | 14 | TEXT ·Syscall(SB),NOSPLIT,$0-56 15 | JMP syscall·Syscall(SB) 16 | 17 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 18 | JMP syscall·Syscall6(SB) 19 | 20 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 21 | JMP syscall·Syscall9(SB) 22 | 23 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 24 | JMP syscall·RawSyscall(SB) 25 | 26 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 27 | JMP syscall·RawSyscall6(SB) 28 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_openbsd_mips64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build gc 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System call support for mips64, OpenBSD 11 | // 12 | 13 | // Just jump to package syscall's implementation for all these functions. 14 | // The runtime may know about them. 15 | 16 | TEXT ·Syscall(SB),NOSPLIT,$0-56 17 | JMP syscall·Syscall(SB) 18 | 19 | TEXT ·Syscall6(SB),NOSPLIT,$0-80 20 | JMP syscall·Syscall6(SB) 21 | 22 | TEXT ·Syscall9(SB),NOSPLIT,$0-104 23 | JMP syscall·Syscall9(SB) 24 | 25 | TEXT ·RawSyscall(SB),NOSPLIT,$0-56 26 | JMP syscall·RawSyscall(SB) 27 | 28 | TEXT ·RawSyscall6(SB),NOSPLIT,$0-80 29 | JMP syscall·RawSyscall6(SB) 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/asm_solaris_amd64.s: -------------------------------------------------------------------------------- 1 | // Copyright 2014 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build gc 6 | 7 | #include "textflag.h" 8 | 9 | // 10 | // System calls for amd64, Solaris are implemented in runtime/syscall_solaris.go 11 | // 12 | 13 | TEXT ·sysvicall6(SB),NOSPLIT,$0-88 14 | JMP syscall·sysvicall6(SB) 15 | 16 | TEXT ·rawSysvicall6(SB),NOSPLIT,$0-88 17 | JMP syscall·rawSysvicall6(SB) 18 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/constants.go: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris || zos 6 | 7 | package unix 8 | 9 | const ( 10 | R_OK = 0x4 11 | W_OK = 0x2 12 | X_OK = 0x1 13 | ) 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/endian_big.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | // 5 | //go:build armbe || arm64be || m68k || mips || mips64 || mips64p32 || ppc || ppc64 || s390 || s390x || shbe || sparc || sparc64 6 | 7 | package unix 8 | 9 | const isBigEndian = true 10 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/endian_little.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | // 5 | //go:build 386 || amd64 || amd64p32 || alpha || arm || arm64 || loong64 || mipsle || mips64le || mips64p32le || nios2 || ppc64le || riscv || riscv64 || sh 6 | 7 | package unix 8 | 9 | const isBigEndian = false 10 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/env_unix.go: -------------------------------------------------------------------------------- 1 | // Copyright 2010 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris || zos 6 | 7 | // Unix environment variables. 8 | 9 | package unix 10 | 11 | import "syscall" 12 | 13 | func Getenv(key string) (value string, found bool) { 14 | return syscall.Getenv(key) 15 | } 16 | 17 | func Setenv(key, value string) error { 18 | return syscall.Setenv(key, value) 19 | } 20 | 21 | func Clearenv() { 22 | syscall.Clearenv() 23 | } 24 | 25 | func Environ() []string { 26 | return syscall.Environ() 27 | } 28 | 29 | func Unsetenv(key string) error { 30 | return syscall.Unsetenv(key) 31 | } 32 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/fcntl_linux_32bit.go: -------------------------------------------------------------------------------- 1 | // Copyright 2014 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (linux && 386) || (linux && arm) || (linux && mips) || (linux && mipsle) || (linux && ppc) 6 | 7 | package unix 8 | 9 | func init() { 10 | // On 32-bit Linux systems, the fcntl syscall that matches Go's 11 | // Flock_t type is SYS_FCNTL64, not SYS_FCNTL. 12 | fcntl64Syscall = SYS_FCNTL64 13 | } 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/gccgo_linux_amd64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2015 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build gccgo && linux && amd64 6 | 7 | package unix 8 | 9 | import "syscall" 10 | 11 | //extern gettimeofday 12 | func realGettimeofday(*Timeval, *byte) int32 13 | 14 | func gettimeofday(tv *Timeval) (err syscall.Errno) { 15 | r := realGettimeofday(tv, nil) 16 | if r < 0 { 17 | return syscall.GetErrno() 18 | } 19 | return 0 20 | } 21 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/mmap_nomremap.go: -------------------------------------------------------------------------------- 1 | // Copyright 2023 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || darwin || dragonfly || freebsd || openbsd || solaris || zos 6 | 7 | package unix 8 | 9 | var mapper = &mmapper{ 10 | active: make(map[*byte][]byte), 11 | mmap: mmap, 12 | munmap: munmap, 13 | } 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/pagesize_unix.go: -------------------------------------------------------------------------------- 1 | // Copyright 2017 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || darwin || dragonfly || freebsd || linux || netbsd || openbsd || solaris || zos 6 | 7 | // For Unix, get the pagesize from the runtime. 8 | 9 | package unix 10 | 11 | import "syscall" 12 | 13 | func Getpagesize() int { 14 | return syscall.Getpagesize() 15 | } 16 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/ptrace_darwin.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build darwin && !ios 6 | 7 | package unix 8 | 9 | func ptrace(request int, pid int, addr uintptr, data uintptr) error { 10 | return ptrace1(request, pid, addr, data) 11 | } 12 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/ptrace_ios.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build ios 6 | 7 | package unix 8 | 9 | func ptrace(request int, pid int, addr uintptr, data uintptr) (err error) { 10 | return ENOTSUP 11 | } 12 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/race.go: -------------------------------------------------------------------------------- 1 | // Copyright 2012 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (darwin && race) || (linux && race) || (freebsd && race) 6 | 7 | package unix 8 | 9 | import ( 10 | "runtime" 11 | "unsafe" 12 | ) 13 | 14 | const raceenabled = true 15 | 16 | func raceAcquire(addr unsafe.Pointer) { 17 | runtime.RaceAcquire(addr) 18 | } 19 | 20 | func raceReleaseMerge(addr unsafe.Pointer) { 21 | runtime.RaceReleaseMerge(addr) 22 | } 23 | 24 | func raceReadRange(addr unsafe.Pointer, len int) { 25 | runtime.RaceReadRange(addr, len) 26 | } 27 | 28 | func raceWriteRange(addr unsafe.Pointer, len int) { 29 | runtime.RaceWriteRange(addr, len) 30 | } 31 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/race0.go: -------------------------------------------------------------------------------- 1 | // Copyright 2012 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || (darwin && !race) || (linux && !race) || (freebsd && !race) || netbsd || openbsd || solaris || dragonfly || zos 6 | 7 | package unix 8 | 9 | import ( 10 | "unsafe" 11 | ) 12 | 13 | const raceenabled = false 14 | 15 | func raceAcquire(addr unsafe.Pointer) { 16 | } 17 | 18 | func raceReleaseMerge(addr unsafe.Pointer) { 19 | } 20 | 21 | func raceReadRange(addr unsafe.Pointer, len int) { 22 | } 23 | 24 | func raceWriteRange(addr unsafe.Pointer, len int) { 25 | } 26 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/readdirent_getdents.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build aix || dragonfly || freebsd || linux || netbsd || openbsd 6 | 7 | package unix 8 | 9 | // ReadDirent reads directory entries from fd and writes them into buf. 10 | func ReadDirent(fd int, buf []byte) (n int, err error) { 11 | return Getdents(fd, buf) 12 | } 13 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/readdirent_getdirentries.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build darwin || zos 6 | 7 | package unix 8 | 9 | import "unsafe" 10 | 11 | // ReadDirent reads directory entries from fd and writes them into buf. 12 | func ReadDirent(fd int, buf []byte) (n int, err error) { 13 | // Final argument is (basep *uintptr) and the syscall doesn't take nil. 14 | // 64 bits should be enough. (32 bits isn't even on 386). Since the 15 | // actual system call is getdirentries64, 64 is a good guess. 16 | // TODO(rsc): Can we use a single global basep for all calls? 17 | var base = (*uintptr)(unsafe.Pointer(new(uint64))) 18 | return Getdirentries(fd, buf, base) 19 | } 20 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/sockcmsg_dragonfly.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package unix 6 | 7 | // Round the length of a raw sockaddr up to align it properly. 8 | func cmsgAlignOf(salen int) int { 9 | salign := SizeofPtr 10 | if SizeofPtr == 8 && !supportsABI(_dragonflyABIChangeVersion) { 11 | // 64-bit Dragonfly before the September 2019 ABI changes still requires 12 | // 32-bit aligned access to network subsystem. 13 | salign = 4 14 | } 15 | return (salen + salign - 1) & ^(salign - 1) 16 | } 17 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_hurd.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build hurd 6 | 7 | package unix 8 | 9 | /* 10 | #include 11 | int ioctl(int, unsigned long int, uintptr_t); 12 | */ 13 | import "C" 14 | 15 | func ioctl(fd int, req uint, arg uintptr) (err error) { 16 | r0, er := C.ioctl(C.int(fd), C.ulong(req), C.uintptr_t(arg)) 17 | if r0 == -1 && er != nil { 18 | err = er 19 | } 20 | return 21 | } 22 | 23 | func ioctlPtr(fd int, req uint, arg unsafe.Pointer) (err error) { 24 | r0, er := C.ioctl(C.int(fd), C.ulong(req), C.uintptr_t(uintptr(arg))) 25 | if r0 == -1 && er != nil { 26 | err = er 27 | } 28 | return 29 | } 30 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_hurd_386.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build 386 && hurd 6 | 7 | package unix 8 | 9 | const ( 10 | TIOCGETA = 0x62251713 11 | ) 12 | 13 | type Winsize struct { 14 | Row uint16 15 | Col uint16 16 | Xpixel uint16 17 | Ypixel uint16 18 | } 19 | 20 | type Termios struct { 21 | Iflag uint32 22 | Oflag uint32 23 | Cflag uint32 24 | Lflag uint32 25 | Cc [20]uint8 26 | Ispeed int32 27 | Ospeed int32 28 | } 29 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_linux_alarm.go: -------------------------------------------------------------------------------- 1 | // Copyright 2022 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build linux && (386 || amd64 || mips || mipsle || mips64 || mipsle || ppc64 || ppc64le || ppc || s390x || sparc64) 6 | 7 | package unix 8 | 9 | // SYS_ALARM is not defined on arm or riscv, but is available for other GOARCH 10 | // values. 11 | 12 | //sys Alarm(seconds uint) (remaining uint, err error) 13 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_linux_amd64_gc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build amd64 && linux && gc 6 | 7 | package unix 8 | 9 | import "syscall" 10 | 11 | //go:noescape 12 | func gettimeofday(tv *Timeval) (err syscall.Errno) 13 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_linux_gc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build linux && gc 6 | 7 | package unix 8 | 9 | // SyscallNoError may be used instead of Syscall for syscalls that don't fail. 10 | func SyscallNoError(trap, a1, a2, a3 uintptr) (r1, r2 uintptr) 11 | 12 | // RawSyscallNoError may be used instead of RawSyscall for syscalls that don't 13 | // fail. 14 | func RawSyscallNoError(trap, a1, a2, a3 uintptr) (r1, r2 uintptr) 15 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_linux_gc_386.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build linux && gc && 386 6 | 7 | package unix 8 | 9 | import "syscall" 10 | 11 | // Underlying system call writes to newoffset via pointer. 12 | // Implemented in assembly to avoid allocation. 13 | func seek(fd int, offset int64, whence int) (newoffset int64, err syscall.Errno) 14 | 15 | func socketcall(call int, a0, a1, a2, a3, a4, a5 uintptr) (n int, err syscall.Errno) 16 | func rawsocketcall(call int, a0, a1, a2, a3, a4, a5 uintptr) (n int, err syscall.Errno) 17 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_linux_gc_arm.go: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build arm && gc && linux 6 | 7 | package unix 8 | 9 | import "syscall" 10 | 11 | // Underlying system call writes to newoffset via pointer. 12 | // Implemented in assembly to avoid allocation. 13 | func seek(fd int, offset int64, whence int) (newoffset int64, err syscall.Errno) 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_linux_gccgo_arm.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build linux && gccgo && arm 6 | 7 | package unix 8 | 9 | import ( 10 | "syscall" 11 | "unsafe" 12 | ) 13 | 14 | func seek(fd int, offset int64, whence int) (int64, syscall.Errno) { 15 | var newoffset int64 16 | offsetLow := uint32(offset & 0xffffffff) 17 | offsetHigh := uint32((offset >> 32) & 0xffffffff) 18 | _, _, err := Syscall6(SYS__LLSEEK, uintptr(fd), uintptr(offsetHigh), uintptr(offsetLow), uintptr(unsafe.Pointer(&newoffset)), uintptr(whence), 0) 19 | return newoffset, err 20 | } 21 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_solaris_amd64.go: -------------------------------------------------------------------------------- 1 | // Copyright 2009 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build amd64 && solaris 6 | 7 | package unix 8 | 9 | func setTimespec(sec, nsec int64) Timespec { 10 | return Timespec{Sec: sec, Nsec: nsec} 11 | } 12 | 13 | func setTimeval(sec, usec int64) Timeval { 14 | return Timeval{Sec: sec, Usec: usec} 15 | } 16 | 17 | func (iov *Iovec) SetLen(length int) { 18 | iov.Len = uint64(length) 19 | } 20 | 21 | func (msghdr *Msghdr) SetIovlen(length int) { 22 | msghdr.Iovlen = int32(length) 23 | } 24 | 25 | func (cmsg *Cmsghdr) SetLen(length int) { 26 | cmsg.Len = uint32(length) 27 | } 28 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/syscall_unix_gc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (darwin || dragonfly || freebsd || (linux && !ppc64 && !ppc64le) || netbsd || openbsd || solaris) && gc 6 | 7 | package unix 8 | 9 | import "syscall" 10 | 11 | func Syscall(trap, a1, a2, a3 uintptr) (r1, r2 uintptr, err syscall.Errno) 12 | func Syscall6(trap, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err syscall.Errno) 13 | func RawSyscall(trap, a1, a2, a3 uintptr) (r1, r2 uintptr, err syscall.Errno) 14 | func RawSyscall6(trap, a1, a2, a3, a4, a5, a6 uintptr) (r1, r2 uintptr, err syscall.Errno) 15 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/sysvshm_linux.go: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build linux 6 | 7 | package unix 8 | 9 | import "runtime" 10 | 11 | // SysvShmCtl performs control operations on the shared memory segment 12 | // specified by id. 13 | func SysvShmCtl(id, cmd int, desc *SysvShmDesc) (result int, err error) { 14 | if runtime.GOARCH == "arm" || 15 | runtime.GOARCH == "mips64" || runtime.GOARCH == "mips64le" { 16 | cmd |= ipc_64 17 | } 18 | 19 | return shmctl(id, cmd, desc) 20 | } 21 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/sysvshm_unix_other.go: -------------------------------------------------------------------------------- 1 | // Copyright 2021 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build (darwin && !ios) || zos 6 | 7 | package unix 8 | 9 | // SysvShmCtl performs control operations on the shared memory segment 10 | // specified by id. 11 | func SysvShmCtl(id, cmd int, desc *SysvShmDesc) (result int, err error) { 12 | return shmctl(id, cmd, desc) 13 | } 14 | -------------------------------------------------------------------------------- /vendor/golang.org/x/sys/unix/zptrace_linux_arm64.go: -------------------------------------------------------------------------------- 1 | // Code generated by linux/mkall.go generatePtraceRegSet("arm64"). DO NOT EDIT. 2 | 3 | package unix 4 | 5 | import "unsafe" 6 | 7 | // PtraceGetRegSetArm64 fetches the registers used by arm64 binaries. 8 | func PtraceGetRegSetArm64(pid, addr int, regsout *PtraceRegsArm64) error { 9 | iovec := Iovec{(*byte)(unsafe.Pointer(regsout)), uint64(unsafe.Sizeof(*regsout))} 10 | return ptracePtr(PTRACE_GETREGSET, pid, uintptr(addr), unsafe.Pointer(&iovec)) 11 | } 12 | 13 | // PtraceSetRegSetArm64 sets the registers used by arm64 binaries. 14 | func PtraceSetRegSetArm64(pid, addr int, regs *PtraceRegsArm64) error { 15 | iovec := Iovec{(*byte)(unsafe.Pointer(regs)), uint64(unsafe.Sizeof(*regs))} 16 | return ptracePtr(PTRACE_SETREGSET, pid, uintptr(addr), unsafe.Pointer(&iovec)) 17 | } 18 | -------------------------------------------------------------------------------- /vendor/golang.org/x/text/internal/language/common.go: -------------------------------------------------------------------------------- 1 | // Code generated by running "go generate" in golang.org/x/text. DO NOT EDIT. 2 | 3 | package language 4 | 5 | // This file contains code common to the maketables.go and the package code. 6 | 7 | // AliasType is the type of an alias in AliasMap. 8 | type AliasType int8 9 | 10 | const ( 11 | Deprecated AliasType = iota 12 | Macro 13 | Legacy 14 | 15 | AliasTypeUnknown AliasType = -1 16 | ) 17 | -------------------------------------------------------------------------------- /vendor/golang.org/x/text/secure/bidirule/bidirule10.0.0.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build go1.10 6 | 7 | package bidirule 8 | 9 | func (t *Transformer) isFinal() bool { 10 | return t.state == ruleLTRFinal || t.state == ruleRTLFinal || t.state == ruleInitial 11 | } 12 | -------------------------------------------------------------------------------- /vendor/golang.org/x/text/secure/bidirule/bidirule9.0.0.go: -------------------------------------------------------------------------------- 1 | // Copyright 2016 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !go1.10 6 | 7 | package bidirule 8 | 9 | func (t *Transformer) isFinal() bool { 10 | if !t.isRTL() { 11 | return true 12 | } 13 | return t.state == ruleLTRFinal || t.state == ruleRTLFinal || t.state == ruleInitial 14 | } 15 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/AUTHORS: -------------------------------------------------------------------------------- 1 | # This source code refers to The Go Authors for copyright purposes. 2 | # The master list of authors is in the main Go distribution, 3 | # visible at https://tip.golang.org/AUTHORS. 4 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/CONTRIBUTORS: -------------------------------------------------------------------------------- 1 | # This source code was written by the Go contributors. 2 | # The master list of contributors is in the main Go distribution, 3 | # visible at https://tip.golang.org/CONTRIBUTORS. 4 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/errors/is_go113.go: -------------------------------------------------------------------------------- 1 | // Copyright 2020 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build go1.13 6 | // +build go1.13 7 | 8 | package errors 9 | 10 | import "errors" 11 | 12 | // Is is errors.Is. 13 | func Is(err, target error) bool { return errors.Is(err, target) } 14 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/flags/proto_legacy_disable.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build !protolegacy 6 | // +build !protolegacy 7 | 8 | package flags 9 | 10 | const protoLegacy = false 11 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/flags/proto_legacy_enable.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build protolegacy 6 | // +build protolegacy 7 | 8 | package flags 9 | 10 | const protoLegacy = true 11 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/genid/doc.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Package genid contains constants for declarations in descriptor.proto 6 | // and the well-known types. 7 | package genid 8 | 9 | import protoreflect "google.golang.org/protobuf/reflect/protoreflect" 10 | 11 | const GoogleProtobuf_package protoreflect.FullName = "google.protobuf" 12 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/genid/empty_gen.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // Code generated by generate-protos. DO NOT EDIT. 6 | 7 | package genid 8 | 9 | import ( 10 | protoreflect "google.golang.org/protobuf/reflect/protoreflect" 11 | ) 12 | 13 | const File_google_protobuf_empty_proto = "google/protobuf/empty.proto" 14 | 15 | // Names for google.protobuf.Empty. 16 | const ( 17 | Empty_message_name protoreflect.Name = "Empty" 18 | Empty_message_fullname protoreflect.FullName = "google.protobuf.Empty" 19 | ) 20 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/genid/goname.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package genid 6 | 7 | // Go names of implementation-specific struct fields in generated messages. 8 | const ( 9 | State_goname = "state" 10 | 11 | SizeCache_goname = "sizeCache" 12 | SizeCacheA_goname = "XXX_sizecache" 13 | 14 | WeakFields_goname = "weakFields" 15 | WeakFieldsA_goname = "XXX_weak" 16 | 17 | UnknownFields_goname = "unknownFields" 18 | UnknownFieldsA_goname = "XXX_unrecognized" 19 | 20 | ExtensionFields_goname = "extensionFields" 21 | ExtensionFieldsA_goname = "XXX_InternalExtensions" 22 | ExtensionFieldsB_goname = "XXX_extensions" 23 | 24 | WeakFieldPrefix_goname = "XXX_weak_" 25 | ) 26 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/genid/map_entry.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package genid 6 | 7 | import protoreflect "google.golang.org/protobuf/reflect/protoreflect" 8 | 9 | // Generic field names and numbers for synthetic map entry messages. 10 | const ( 11 | MapEntry_Key_field_name protoreflect.Name = "key" 12 | MapEntry_Value_field_name protoreflect.Name = "value" 13 | 14 | MapEntry_Key_field_number protoreflect.FieldNumber = 1 15 | MapEntry_Value_field_number protoreflect.FieldNumber = 2 16 | ) 17 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/genid/wrappers.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package genid 6 | 7 | import protoreflect "google.golang.org/protobuf/reflect/protoreflect" 8 | 9 | // Generic field name and number for messages in wrappers.proto. 10 | const ( 11 | WrapperValue_Value_field_name protoreflect.Name = "value" 12 | WrapperValue_Value_field_number protoreflect.FieldNumber = 1 13 | ) 14 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/internal/strs/strings_pure.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | //go:build purego || appengine 6 | // +build purego appengine 7 | 8 | package strs 9 | 10 | import pref "google.golang.org/protobuf/reflect/protoreflect" 11 | 12 | func UnsafeString(b []byte) string { 13 | return string(b) 14 | } 15 | 16 | func UnsafeBytes(s string) []byte { 17 | return []byte(s) 18 | } 19 | 20 | type Builder struct{} 21 | 22 | func (*Builder) AppendFullName(prefix pref.FullName, name pref.Name) pref.FullName { 23 | return prefix.Append(name) 24 | } 25 | 26 | func (*Builder) MakeString(b []byte) string { 27 | return string(b) 28 | } 29 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/proto/proto_methods.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // The protoreflect build tag disables use of fast-path methods. 6 | //go:build !protoreflect 7 | // +build !protoreflect 8 | 9 | package proto 10 | 11 | import ( 12 | "google.golang.org/protobuf/reflect/protoreflect" 13 | "google.golang.org/protobuf/runtime/protoiface" 14 | ) 15 | 16 | const hasProtoMethods = true 17 | 18 | func protoMethods(m protoreflect.Message) *protoiface.Methods { 19 | return m.ProtoMethods() 20 | } 21 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/proto/proto_reflect.go: -------------------------------------------------------------------------------- 1 | // Copyright 2019 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | // The protoreflect build tag disables use of fast-path methods. 6 | //go:build protoreflect 7 | // +build protoreflect 8 | 9 | package proto 10 | 11 | import ( 12 | "google.golang.org/protobuf/reflect/protoreflect" 13 | "google.golang.org/protobuf/runtime/protoiface" 14 | ) 15 | 16 | const hasProtoMethods = false 17 | 18 | func protoMethods(m protoreflect.Message) *protoiface.Methods { 19 | return nil 20 | } 21 | -------------------------------------------------------------------------------- /vendor/google.golang.org/protobuf/runtime/protoiface/legacy.go: -------------------------------------------------------------------------------- 1 | // Copyright 2018 The Go Authors. All rights reserved. 2 | // Use of this source code is governed by a BSD-style 3 | // license that can be found in the LICENSE file. 4 | 5 | package protoiface 6 | 7 | type MessageV1 interface { 8 | Reset() 9 | String() string 10 | ProtoMessage() 11 | } 12 | 13 | type ExtensionRangeV1 struct { 14 | Start, End int32 // both inclusive 15 | } 16 | -------------------------------------------------------------------------------- /vendor/gopkg.in/natefinch/lumberjack.v2/.gitignore: -------------------------------------------------------------------------------- 1 | # Compiled Object files, Static and Dynamic libs (Shared Objects) 2 | *.o 3 | *.a 4 | *.so 5 | 6 | # Folders 7 | _obj 8 | _test 9 | 10 | # Architecture specific extensions/prefixes 11 | *.[568vq] 12 | [568vq].out 13 | 14 | *.cgo1.go 15 | *.cgo2.c 16 | _cgo_defun.c 17 | _cgo_gotypes.go 18 | _cgo_export.* 19 | 20 | _testmain.go 21 | 22 | *.exe 23 | *.test 24 | -------------------------------------------------------------------------------- /vendor/gopkg.in/natefinch/lumberjack.v2/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | 3 | go: 4 | - 1.8 5 | - 1.7 6 | - 1.6 -------------------------------------------------------------------------------- /vendor/gopkg.in/natefinch/lumberjack.v2/chown.go: -------------------------------------------------------------------------------- 1 | // +build !linux 2 | 3 | package lumberjack 4 | 5 | import ( 6 | "os" 7 | ) 8 | 9 | func chown(_ string, _ os.FileInfo) error { 10 | return nil 11 | } 12 | -------------------------------------------------------------------------------- /vendor/gopkg.in/natefinch/lumberjack.v2/chown_linux.go: -------------------------------------------------------------------------------- 1 | package lumberjack 2 | 3 | import ( 4 | "os" 5 | "syscall" 6 | ) 7 | 8 | // os_Chown is a var so we can mock it out during tests. 9 | var os_Chown = os.Chown 10 | 11 | func chown(name string, info os.FileInfo) error { 12 | f, err := os.OpenFile(name, os.O_CREATE|os.O_WRONLY|os.O_TRUNC, info.Mode()) 13 | if err != nil { 14 | return err 15 | } 16 | f.Close() 17 | stat := info.Sys().(*syscall.Stat_t) 18 | return os_Chown(name, int(stat.Uid), int(stat.Gid)) 19 | } 20 | -------------------------------------------------------------------------------- /vendor/gopkg.in/yaml.v2/.travis.yml: -------------------------------------------------------------------------------- 1 | language: go 2 | 3 | go: 4 | - "1.4.x" 5 | - "1.5.x" 6 | - "1.6.x" 7 | - "1.7.x" 8 | - "1.8.x" 9 | - "1.9.x" 10 | - "1.10.x" 11 | - "1.11.x" 12 | - "1.12.x" 13 | - "1.13.x" 14 | - "1.14.x" 15 | - "tip" 16 | 17 | go_import_path: gopkg.in/yaml.v2 18 | -------------------------------------------------------------------------------- /vendor/gopkg.in/yaml.v2/NOTICE: -------------------------------------------------------------------------------- 1 | Copyright 2011-2016 Canonical Ltd. 2 | 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, software 10 | distributed under the License is distributed on an "AS IS" BASIS, 11 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | See the License for the specific language governing permissions and 13 | limitations under the License. 14 | -------------------------------------------------------------------------------- /vendor/gopkg.in/yaml.v2/writerc.go: -------------------------------------------------------------------------------- 1 | package yaml 2 | 3 | // Set the writer error and return false. 4 | func yaml_emitter_set_writer_error(emitter *yaml_emitter_t, problem string) bool { 5 | emitter.error = yaml_WRITER_ERROR 6 | emitter.problem = problem 7 | return false 8 | } 9 | 10 | // Flush the output buffer. 11 | func yaml_emitter_flush(emitter *yaml_emitter_t) bool { 12 | if emitter.write_handler == nil { 13 | panic("write handler not set") 14 | } 15 | 16 | // Check if the buffer is empty. 17 | if emitter.buffer_pos == 0 { 18 | return true 19 | } 20 | 21 | if err := emitter.write_handler(emitter, emitter.buffer[:emitter.buffer_pos]); err != nil { 22 | return yaml_emitter_set_writer_error(emitter, "write error: "+err.Error()) 23 | } 24 | emitter.buffer_pos = 0 25 | return true 26 | } 27 | -------------------------------------------------------------------------------- /vendor/gopkg.in/yaml.v3/NOTICE: -------------------------------------------------------------------------------- 1 | Copyright 2011-2016 Canonical Ltd. 2 | 3 | Licensed under the Apache License, Version 2.0 (the "License"); 4 | you may not use this file except in compliance with the License. 5 | You may obtain a copy of the License at 6 | 7 | http://www.apache.org/licenses/LICENSE-2.0 8 | 9 | Unless required by applicable law or agreed to in writing, software 10 | distributed under the License is distributed on an "AS IS" BASIS, 11 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 | See the License for the specific language governing permissions and 13 | limitations under the License. 14 | --------------------------------------------------------------------------------