- Sort Score
- Result 10 results
- Languages All
Results 61 - 70 of 546 for Map (0.02 sec)
-
src/archive/zip/register.go
defer r.mu.Unlock() var err error if r.fr != nil { err = r.fr.Close() flateReaderPool.Put(r.fr) r.fr = nil } return err } var ( compressors sync.Map // map[uint16]Compressor decompressors sync.Map // map[uint16]Decompressor ) func init() { compressors.Store(Store, Compressor(func(w io.Writer) (io.WriteCloser, error) { return &nopCloser{w}, nil }))
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Oct 13 18:36:46 UTC 2023 - 3.7K bytes - Viewed (0) -
src/cmd/compile/internal/ssa/flags_test.go
import ( "runtime" "testing" ) func TestAddFlagsNative(t *testing.T) { var numbers = []int64{ 1, 0, -1, 2, -2, 1<<63 - 1, -1 << 63, } coverage := map[flagConstant]bool{} for _, x := range numbers { for _, y := range numbers { a := addFlags64(x, y) b := flagRegister2flagConstant(asmAddFlags(x, y), false) if a != b {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Oct 04 19:36:17 UTC 2022 - 2.5K bytes - Viewed (0) -
src/internal/types/testdata/fixedbugs/issue49179.go
} // test case from the issue type SliceConstraint[T any] interface { []T } func Map[S SliceConstraint[E], E any](s S, f func(E) E) S { return s } type MySlice []int func f(s MySlice) { Map[MySlice /* ERROR "MySlice does not satisfy SliceConstraint[int] (possibly missing ~ for []int in SliceConstraint[int])" */, int](s, nil)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Jan 17 19:54:27 UTC 2023 - 964 bytes - Viewed (0) -
src/reflect/export_test.go
func MapBucketOf(x, y Type) Type { return toType(bucketOf(x.common(), y.common())) } func CachedBucketOf(m Type) Type { t := m.(*rtype) if Kind(t.t.Kind_&abi.KindMask) != Map { panic("not map") } tt := (*mapType)(unsafe.Pointer(t)) return toType(tt.Bucket) } type EmbedWithUnexpMeth struct{} func (EmbedWithUnexpMeth) f() {} type pinUnexpMeth interface { f() }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 02 15:10:48 UTC 2024 - 3.8K bytes - Viewed (0) -
src/cmd/compile/internal/types2/resolver_test.go
files = append(files, mustParse(src)) } // resolve and type-check package AST importer := new(resolveTestImporter) conf := Config{Importer: importer} uses := make(map[*syntax.Name]Object) defs := make(map[*syntax.Name]Object) _, err := conf.Check("testResolveIdents", files, &Info{Defs: defs, Uses: uses}) if err != nil { t.Fatal(err) } // check that all packages were imported
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 10 12:59:20 UTC 2023 - 4.7K bytes - Viewed (0) -
src/net/rpc/jsonrpc/all_test.go
go ServeConn(srv) client := NewClient(cli) defer client.Close() // Map arg := 7 replyMap := map[int]int{} err := client.Call("BuiltinTypes.Map", arg, &replyMap) if err != nil { t.Errorf("Map: expected no error but got string %q", err.Error()) } if replyMap[arg] != arg { t.Errorf("Map: expected %d got %d", arg, replyMap[arg]) } // Slice replySlice := []int{}
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Sep 07 01:09:53 UTC 2022 - 7.8K bytes - Viewed (0) -
src/internal/types/testdata/fixedbugs/issue61879.go
args: args, } } func (k *ImplA[T]) setData(data string) InterfaceA[T] { k.data = data return k } func Foo[M ~map[InterfaceA[T]]V, T comparable, V any](m M) { // DO SOMETHING HERE return } func Bar() { keys := make([]InterfaceA[int], 0, 10) m := make(map[InterfaceA[int]]int) for i := 0; i < 10; i++ { keys = append(keys, NewInterfaceA[int](i)) m[keys[i]] = i } Foo(m) // panic here
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Aug 15 19:42:56 UTC 2023 - 1K bytes - Viewed (0) -
src/plugin/plugin_dlopen.go
// This function can be called from the init function of a plugin. // Drop a placeholder in the map so subsequent opens can wait on it. p := &Plugin{ pluginpath: pluginpath, loaded: make(chan struct{}), } plugins[filepath] = p pluginsMu.Unlock() doInit(initTasks) // Fill out the value of each plugin symbol. updatedSyms := map[string]any{} for symName, sym := range syms { isFunc := symName[0] == '.'
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Apr 14 16:55:22 UTC 2023 - 3.9K bytes - Viewed (0) -
src/cmd/vendor/github.com/google/pprof/profile/prune.go
func (p *Profile) Prune(dropRx, keepRx *regexp.Regexp) { prune := make(map[uint64]bool) pruneBeneath := make(map[uint64]bool) // simplifyFunc can be expensive, so cache results. // Note that the same function name can be encountered many times due // different lines and addresses in the same function. pruneCache := map[string]bool{} // Map from function to whether or not to prune pruneFromHere := func(s string) bool {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Nov 22 18:58:12 UTC 2022 - 5.5K bytes - Viewed (0) -
src/cmd/go/testdata/script/list_importmap.txt
stdout '^flag \[fmt\.test\] MAP: map\[fmt:fmt \[fmt\.test\]\]' stdout '^fmt\.test MAP: map\[(.* )?testing:testing \[fmt\.test\]' ! stdout '^fmt\.test MAP: map\[(.* )?os:' stdout '^fmt\.test IMPORT: \[fmt \[fmt\.test\] fmt_test \[fmt\.test\] os reflect testing \[fmt\.test\] testing/internal/testdeps \[fmt\.test\]\]' -- a/b/b.go -- package b import _ "c/d" -- a/vendor/c/d/d.go --
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Oct 24 21:26:10 UTC 2022 - 956 bytes - Viewed (0)