Search Options

Results per page
Sort
Preferred Languages
Advance

Results 91 - 100 of 1,614 for qsort (0.07 sec)

  1. pkg/apis/rbac/v1/helpers.go

    		}
    	default:
    		return rbacv1.PolicyRule{}, fmt.Errorf("a rule must have either nonResourceURLs or resources: %#v", r.PolicyRule)
    	}
    
    	sort.Strings(r.PolicyRule.Resources)
    	sort.Strings(r.PolicyRule.ResourceNames)
    	sort.Strings(r.PolicyRule.APIGroups)
    	sort.Strings(r.PolicyRule.NonResourceURLs)
    	sort.Strings(r.PolicyRule.Verbs)
    	return r.PolicyRule, nil
    }
    
    // +k8s:deepcopy-gen=false
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed Jan 18 15:37:57 UTC 2023
    - 7.4K bytes
    - Viewed (0)
  2. istioctl/pkg/config/config.go

    			return runList(c.OutOrStdout())
    		},
    	}
    	return listCmd
    }
    
    func runList(writer io.Writer) error {
    	// Sort flag names
    	keys := make([]string, len(settableFlags))
    	i := 0
    	for key := range settableFlags {
    		keys[i] = key
    		i++
    	}
    	sort.Strings(keys)
    	w := new(tabwriter.Writer).Init(writer, 0, 8, 5, ' ', 0)
    	fmt.Fprintf(w, "FLAG\tVALUE\tFROM\n")
    	for _, flag := range keys {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Sun Jul 30 12:16:07 UTC 2023
    - 3.1K bytes
    - Viewed (0)
  3. src/internal/types/testdata/fixedbugs/issue58611.go

    package p
    
    import (
    	"sort"
    	"strings"
    )
    
    func f[int any](x int) {
    	x = 0 /* ERRORx "cannot use 0.*(as int.*with int declared at|type parameter)" */
    }
    
    // test case from issue
    
    type Set[T comparable] map[T]struct{}
    
    func (s *Set[string]) String() string {
    	keys := make([]string, 0, len(*s))
    	for k := range *s {
    		keys = append(keys, k)
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Feb 22 00:40:19 UTC 2023
    - 742 bytes
    - Viewed (0)
  4. pkg/config/analysis/analyzers/multicluster/service.go

    }
    
    func compareServicePorts(a, b []corev1.ServicePort) bool {
    	if len(a) != len(b) {
    		return false
    	}
    
    	sort.SliceStable(a, func(i, j int) bool {
    		return a[i].Name < a[j].Name
    	})
    
    	sort.SliceStable(b, func(i, j int) bool {
    		return b[i].Name < b[j].Name
    	})
    	return reflect.DeepEqual(a, b)
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Apr 02 08:32:06 UTC 2024
    - 4.3K bytes
    - Viewed (0)
  5. android/guava-testlib/src/com/google/common/collect/testing/testers/SortedMapNavigationTester.java

        List<Entry<K, V>> entries =
            Helpers.copyToList(
                getSubjectGenerator()
                    .getSampleElements(getSubjectGenerator().getCollectionSize().getNumElements()));
        Collections.sort(entries, Helpers.<K, V>entryComparator(navigableMap.comparator()));
    
        // some tests assume SEVERAL == 3
        if (entries.size() >= 1) {
          a = entries.get(0);
          if (entries.size() >= 3) {
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Tue Feb 20 17:00:05 UTC 2024
    - 6.1K bytes
    - Viewed (0)
  6. test/typeparam/mapsimp.dir/main.go

    import (
    	"./a"
    	"fmt"
    	"math"
    	"sort"
    )
    
    var m1 = map[int]int{1: 2, 2: 4, 4: 8, 8: 16}
    var m2 = map[int]string{1: "2", 2: "4", 4: "8", 8: "16"}
    
    func TestKeys() {
    	want := []int{1, 2, 4, 8}
    
    	got1 := a.Keys(m1)
    	sort.Ints(got1)
    	if !a.SliceEqual(got1, want) {
    		panic(fmt.Sprintf("a.Keys(%v) = %v, want %v", m1, got1, want))
    	}
    
    	got2 := a.Keys(m2)
    	sort.Ints(got2)
    	if !a.SliceEqual(got2, want) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 24 02:14:15 UTC 2022
    - 3.6K bytes
    - Viewed (0)
  7. pilot/pkg/config/monitor/file_snapshot.go

    				continue
    			}
    			result = append(result, cfg)
    		}
    		return nil
    	})
    	if err != nil {
    		log.Warnf("failure during filepath.Walk: %v", err)
    	}
    
    	// Sort by the config IDs.
    	sort.Sort(byKey(result))
    	return result, err
    }
    
    // parseInputs is identical to crd.ParseInputs, except that it returns an array of config pointers.
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Feb 12 17:36:33 UTC 2024
    - 3.6K bytes
    - Viewed (0)
  8. src/cmd/internal/objfile/plan9obj.go

    	for _, s := range plan9Syms {
    		if !validSymType[s.Type] {
    			continue
    		}
    		addrs = append(addrs, s.Value)
    	}
    	sort.Sort(uint64s(addrs))
    
    	var syms []Sym
    
    	for _, s := range plan9Syms {
    		if !validSymType[s.Type] {
    			continue
    		}
    		sym := Sym{Addr: s.Value, Name: s.Name, Code: s.Type}
    		i := sort.Search(len(addrs), func(x int) bool { return addrs[x] > s.Value })
    		if i < len(addrs) {
    			sym.Size = int64(addrs[i] - s.Value)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Sep 21 01:01:44 UTC 2017
    - 3.5K bytes
    - Viewed (0)
  9. pkg/test/framework/components/echo/services.go

    	out := d.Copy()
    	for _, o := range others {
    		out = append(out, o...)
    	}
    	sort.Stable(out)
    	return out
    }
    
    func (d Services) NamespacedNames() NamespacedNames {
    	out := make(NamespacedNames, 0, d.Len())
    	for _, svc := range d {
    		out = append(out, svc.NamespacedName())
    	}
    
    	sort.Stable(out)
    	return out
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Apr 21 16:42:24 UTC 2022
    - 3.1K bytes
    - Viewed (0)
  10. build-logic/binary-compatibility/src/main/groovy/gradlebuild/EnrichedReportRenderer.groovy

                        });
                        // Sort the array in place by type, then member
                        // Note that Firefox is fine with a sort function returning any positive or negative number, but Chrome 
                        // requires 1 or -1 specifically and ignores higher or lower values.  This sort ought to remain consistent
                        // with the sort used by AbstractAcceptedApiChangesMaintenanceTask.
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue Feb 07 20:38:43 UTC 2023
    - 7.2K bytes
    - Viewed (0)
Back to top