Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 94 for decls (0.04 sec)

  1. src/net/http/clientserver_test.go

    func testTrailersClientToServer(t *testing.T, mode testMode) {
    	cst := newClientServerTest(t, mode, HandlerFunc(func(w ResponseWriter, r *Request) {
    		var decl []string
    		for k := range r.Trailer {
    			decl = append(decl, k)
    		}
    		slices.Sort(decl)
    
    		slurp, err := io.ReadAll(r.Body)
    		if err != nil {
    			t.Errorf("Server reading request body: %v", err)
    		}
    		if string(slurp) != "foo" {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:00:11 UTC 2024
    - 46.6K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/syntax/positions.go

    		case *CommClause:
    			if l := lastStmt(n.Body); l != nil {
    				m = l
    				continue
    			}
    			return n.Colon
    
    		default:
    			return n.Pos()
    		}
    	}
    }
    
    func lastDecl(list []Decl) Decl {
    	if l := len(list); l > 0 {
    		return list[l-1]
    	}
    	return nil
    }
    
    func lastExpr(list []Expr) Expr {
    	if l := len(list); l > 0 {
    		return list[l-1]
    	}
    	return nil
    }
    
    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. src/internal/types/testdata/check/decls2/decls2a.go

    // Copyright 2012 The Go Authors. All rights reserved.
    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    // method declarations
    
    package decls2
    
    import "time"
    import "unsafe"
    
    // T1 declared before its methods.
    type T1 struct{
    	f int
    }
    
    func (T1) m() {}
    func (T1) m /* ERROR "already declared" */ () {}
    func (x *T1) f /* ERROR "field and method with the same name f" */ () {}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 3.3K bytes
    - Viewed (0)
  4. staging/src/k8s.io/apiextensions-apiserver/pkg/apiserver/schema/cel/model/schemas_test.go

    			ExpectedMaxElements: 20,
    		},
    	}
    	for _, testCase := range tests {
    		t.Run(testCase.Name, func(t *testing.T) {
    			decl := SchemaDeclType(testCase.InputSchema, false)
    			if decl.MaxElements != testCase.ExpectedMaxElements {
    				t.Errorf("wrong maxElements (got %d, expected %d)", decl.MaxElements, testCase.ExpectedMaxElements)
    			}
    		})
    	}
    }
    
    func maxPtr(max int64) *int64 {
    	return &max
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu May 16 20:13:14 UTC 2024
    - 14K bytes
    - Viewed (0)
  5. staging/src/k8s.io/apiextensions-apiserver/pkg/controller/establish/establishing_controller.go

    	go wait.Until(ec.runWorker, time.Second, stopCh)
    
    	<-stopCh
    }
    
    func (ec *EstablishingController) runWorker() {
    	for ec.processNextWorkItem() {
    	}
    }
    
    // processNextWorkItem deals with one key off the queue.
    // It returns false when it's time to quit.
    func (ec *EstablishingController) processNextWorkItem() bool {
    	key, quit := ec.queue.Get()
    	if quit {
    		return false
    	}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat May 04 18:33:12 UTC 2024
    - 4.4K bytes
    - Viewed (0)
  6. src/text/template/exec.go

    	mark := s.mark()
    	oneIteration := func(index, elem reflect.Value) {
    		if len(r.Pipe.Decl) > 0 {
    			if r.Pipe.IsAssign {
    				// With two variables, index comes first.
    				// With one, we use the element.
    				if len(r.Pipe.Decl) > 1 {
    					s.setVar(r.Pipe.Decl[0].Ident[0], index)
    				} else {
    					s.setVar(r.Pipe.Decl[0].Ident[0], elem)
    				}
    			} else {
    				// Set top var (lexically the second if there
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 24 21:22:24 UTC 2024
    - 32K bytes
    - Viewed (0)
  7. src/cmd/compile/internal/types2/resolver.go

    		var last *syntax.ConstDecl // last ConstDecl with init expressions, or nil
    		for index, decl := range file.DeclList {
    			if _, ok := decl.(*syntax.ConstDecl); !ok {
    				first = -1 // we're not in a constant declaration
    			}
    
    			switch s := decl.(type) {
    			case *syntax.ImportDecl:
    				// import package
    				if s.Path == nil || s.Path.Bad {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 18 14:10:44 UTC 2024
    - 26.3K bytes
    - Viewed (0)
  8. platforms/software/dependency-management/src/test/groovy/org/gradle/api/internal/artifacts/result/DefaultResolutionResultTest.groovy

            then:
            deps*.requested.group == ['dep1', 'dep3', 'dep2', 'dep3']
    
            and:
            modules*.id.group == ['root', 'dep1', 'dep3', 'dep2']
        }
    
        def "deals with dependency cycles"() {
            given:
            // a->b->a
            def root = newModule('a', 'a', '1')
            def dep1 = newDependency('b', 'b', '1')
            root.addDependency(dep1)
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu May 23 17:36:01 UTC 2024
    - 6.4K bytes
    - Viewed (0)
  9. src/cmd/compile/internal/types2/check.go

    	environment
    
    	// debugging
    	indent int // indentation for tracing
    }
    
    // addDeclDep adds the dependency edge (check.decl -> to) if check.decl exists
    func (check *Checker) addDeclDep(to Object) {
    	from := check.decl
    	if from == nil {
    		return // not in a package-level init expression
    	}
    	if _, found := check.objMap[to]; !found {
    		return // to is not a package-level object
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:19:55 UTC 2024
    - 23.3K bytes
    - Viewed (0)
  10. pkg/controller/certificates/certificate_controller.go

    // worker runs a thread that dequeues CSRs, handles them, and marks them done.
    func (cc *CertificateController) worker(ctx context.Context) {
    	for cc.processNextWorkItem(ctx) {
    	}
    }
    
    // processNextWorkItem deals with one key off the queue.  It returns false when it's time to quit.
    func (cc *CertificateController) processNextWorkItem(ctx context.Context) bool {
    	cKey, quit := cc.queue.Get()
    	if quit {
    		return false
    	}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat May 04 18:33:12 UTC 2024
    - 6.4K bytes
    - Viewed (0)
Back to top