Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 3,099 for case1 (0.09 sec)

  1. src/cmd/vendor/golang.org/x/text/internal/tag/tag.go

    func cmp(a Index, b []byte) int {
    	n := len(a)
    	if len(b) < n {
    		n = len(b)
    	}
    	for i, c := range b[:n] {
    		switch {
    		case a[i] > c:
    			return 1
    		case a[i] < c:
    			return -1
    		}
    	}
    	switch {
    	case len(a) < len(b):
    		return -1
    	case len(a) > len(b):
    		return 1
    	}
    	return 0
    }
    
    // Compare returns an integer comparing a and b lexicographically.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 24 13:01:26 UTC 2024
    - 2.4K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/syntax/positions.go

    		// case *MapType:
    		// case *ChanType:
    
    		// statements
    		// case *EmptyStmt:
    		// case *LabeledStmt:
    		// case *BlockStmt:
    		// case *ExprStmt:
    		case *SendStmt:
    			m = n.Chan
    		// case *DeclStmt:
    		case *AssignStmt:
    			m = n.Lhs
    		// case *BranchStmt:
    		// case *CallStmt:
    		// case *ReturnStmt:
    		// case *IfStmt:
    		// case *ForStmt:
    		// case *SwitchStmt:
    		// case *SelectStmt:
    
    		// helper nodes
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 10 17:49:19 UTC 2024
    - 6.5K bytes
    - Viewed (0)
  3. cmd/erasure-metadata-utils_test.go

    func TestReduceErrs(t *testing.T) {
    	canceledErrs := make([]error, 0, 5)
    	for i := 0; i < 5; i++ {
    		canceledErrs = append(canceledErrs, fmt.Errorf("error %d: %w", i, context.Canceled))
    	}
    	// List all of all test cases to validate various cases of reduce errors.
    	testCases := []struct {
    		errs        []error
    		ignoredErrs []error
    		err         error
    	}{
    		// Validate if have reduced properly.
    		{[]error{
    			errDiskNotFound,
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Thu Jan 18 07:03:17 UTC 2024
    - 7.4K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/types2/under.go

    // If x and y are identical channels but for their direction
    // and one of them is unrestricted, match returns the channel
    // with the restricted direction.
    // In all other cases, match returns nil.
    func match(x, y Type) Type {
    	// Common case: we don't have channels.
    	if Identical(x, y) {
    		return x
    	}
    
    	// We may have channels that differ in direction only.
    	if x, _ := x.(*Chan); x != nil {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 21 22:34:27 UTC 2024
    - 2.7K bytes
    - Viewed (0)
  5. pilot/pkg/server/instance_test.go

    		completed: atomic.NewBool(false),
    		d:         d,
    		stop:      stop,
    	}
    }
    
    func (c *fakeComponent) Run(stop <-chan struct{}) error {
    	c.started.Store(true)
    	select {
    	case <-time.After(c.d):
    	case <-c.stop: // ignore incoming stop; for test purposes we use our own stop
    	}
    	c.completed.Store(true)
    	return nil
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Apr 30 23:02:39 UTC 2024
    - 4.1K bytes
    - Viewed (0)
  6. cmd/object-handlers_test.go

    				switch test.fault {
    				case MissingContentLength:
    					req.ContentLength = -1
    					// Setting the content length to a value greater than the max allowed size of a part.
    					// Used in test case  4.
    				case TooBigObject:
    					req.ContentLength = globalMaxObjectSize + 1
    					// Malformed signature.
    					// Used in test case  6.
    				case BadSignature:
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Mon Jun 10 15:50:49 UTC 2024
    - 161.9K bytes
    - Viewed (0)
  7. src/go/types/selection.go

    //
    //	"field (T) f int"
    //	"method (T) f(X) Y"
    //	"method expr (T) f(X) Y"
    func SelectionString(s *Selection, qf Qualifier) string {
    	var k string
    	switch s.kind {
    	case FieldVal:
    		k = "field "
    	case MethodVal:
    		k = "method "
    	case MethodExpr:
    		k = "method expr "
    	default:
    		panic("unreachable")
    	}
    	var buf bytes.Buffer
    	buf.WriteString(k)
    	buf.WriteByte('(')
    	WriteType(&buf, s.Recv(), qf)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 03 18:48:38 UTC 2024
    - 5.9K bytes
    - Viewed (0)
  8. platforms/core-configuration/configuration-cache/src/integTest/groovy/org/gradle/internal/cc/impl/inputs/process/instrument/Execute1StaticInstrumentationInDynamicGroovyWithoutIndyIntegrationTest.groovy

     * limitations under the License.
     */
    
    package org.gradle.internal.cc.impl.inputs.process.instrument
    
    /**
     * Test cases for single-argument {@code ProcessGroovyMethods.execute} with static import (Groovy produces a special byte code in this case):
     * <pre>
     *     import static org.codehaus.groovy.runtime.ProcessGroovyMethods.execute
     *     execute("echo 123")
     *     execute(["echo", "123"])
     * </pre>
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Sat Jun 08 11:29:25 UTC 2024
    - 1.2K bytes
    - Viewed (0)
  9. src/cmd/compile/internal/types2/subst.go

    	assert(expanding != nil || ctxt != nil)
    
    	if smap.empty() {
    		return typ
    	}
    
    	// common cases
    	switch t := typ.(type) {
    	case *Basic:
    		return typ // nothing to do
    	case *TypeParam:
    		return smap.lookup(t)
    	}
    
    	// general case
    	subst := subster{
    		pos:       pos,
    		smap:      smap,
    		check:     check,
    		expanding: expanding,
    		ctxt:      ctxt,
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 03:04:07 UTC 2024
    - 11K bytes
    - Viewed (0)
  10. pilot/pkg/leaderelection/leaderelection_test.go

    			for _, comp := range []string{"location", "simple"} {
    				cases = append(cases, instance{
    					revision: rev,
    					remote:   loc,
    					comp:     comp,
    				})
    			}
    		}
    	}
    
    	for _, start := range cases {
    		t.Run(fmt.Sprint(start), func(t *testing.T) {
    			checkCycles(t, start, cases, nil)
    		})
    	}
    }
    
    func alreadyHit(cur instance, chain []instance) bool {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Sun Apr 28 04:22:19 UTC 2024
    - 11.4K bytes
    - Viewed (0)
Back to top