Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 124 for newBar (0.12 sec)

  1. src/cmd/compile/internal/inline/inlheur/testdata/props/returns2.go

    	x int
    	y string
    }
    
    func (b *Bar) Plark() Itf {
    	return b
    }
    
    type Itf interface {
    	Plark() Itf
    }
    
    func newBar(x int) Itf {
    	s := 0
    	for i := 0; i < x; i++ {
    		s += i
    	}
    	return &Bar{
    		x: s,
    	}
    }
    
    func newBar2(x int) (int, Itf, bool) {
    	s := 0
    	for i := 0; i < x; i++ {
    		s += i
    	}
    	return 0, &Bar{x: s}, false
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 16 20:15:01 UTC 2023
    - 5.7K bytes
    - Viewed (0)
  2. test/fixedbugs/issue5581.go

    // Copyright 2013 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.
    
    package main
    
    import "fmt"
    
    func NewBar() *Bar { return nil }
    
    func (x *Foo) Method() (int, error) {
    	for y := range x.m {
    		_ = y.A
    	}
    	return 0, nil
    }
    
    type Foo struct {
    	m map[*Bar]int
    }
    
    type Bar struct {
    	A *Foo
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 02 13:43:18 UTC 2016
    - 575 bytes
    - Viewed (0)
  3. subprojects/composite-builds/src/integTest/groovy/org/gradle/integtests/composite/plugins/PluginBuildsIntegrationTest.groovy

                }
                dependencies {
                    implementation("${build.group}:${build.buildName}")
                }
            """
            file("src/main/java/Foo.java") << """
                class Foo { Bar newBar() { return new Bar(); }}
            """
    
            then:
            succeeds("build")
            executed(":${build.buildName}:compileJava")
            executed(":compileJava")
            build.assertProjectPluginApplied()
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Fri Jan 06 08:15:28 UTC 2023
    - 18.4K bytes
    - Viewed (0)
  4. test/escape2.go

    	*xxx = &y
    }
    
    func foo19(y int) {
    	**xxx = y
    }
    
    type Bar struct {
    	i  int
    	ii *int
    }
    
    func NewBar() *Bar {
    	return &Bar{42, nil} // ERROR "&Bar{...} escapes to heap$"
    }
    
    func NewBarp(x *int) *Bar { // ERROR "leaking param: x$"
    	return &Bar{42, x} // ERROR "&Bar{...} escapes to heap$"
    }
    
    func NewBarp2(x *int) *Bar { // ERROR "x does not escape$"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Dec 14 17:22:18 UTC 2023
    - 35.1K bytes
    - Viewed (0)
  5. test/escape2n.go

    	*xxx = &y
    }
    
    func foo19(y int) {
    	**xxx = y
    }
    
    type Bar struct {
    	i  int
    	ii *int
    }
    
    func NewBar() *Bar {
    	return &Bar{42, nil} // ERROR "&Bar{...} escapes to heap$"
    }
    
    func NewBarp(x *int) *Bar { // ERROR "leaking param: x$"
    	return &Bar{42, x} // ERROR "&Bar{...} escapes to heap$"
    }
    
    func NewBarp2(x *int) *Bar { // ERROR "x does not escape$"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Dec 14 17:22:18 UTC 2023
    - 35.1K bytes
    - Viewed (0)
  6. pkg/apis/certificates/v1beta1/defaults_test.go

    		"defaults for kubelet-serving": {
    			req:    newCSR(kubeletServerPEMOptions),
    			usages: kubeletServerUsages,
    			exp:    true,
    		},
    		"defaults without key encipherment for kubelet-serving": {
    			req:    newCSR(kubeletServerPEMOptions),
    			usages: kubeletServerUsagesNoRSA,
    			exp:    true,
    		},
    		"does not default to kube-apiserver-client-kubelet if org is not 'system:nodes'": {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Dec 27 08:04:25 UTC 2022
    - 16.9K bytes
    - Viewed (0)
  7. pkg/registry/certificates/certificates/strategy.go

    	newCSR := obj.(*certificates.CertificateSigningRequest)
    	oldCSR := old.(*certificates.CertificateSigningRequest)
    
    	populateConditionTimestamps(newCSR, oldCSR)
    	newConditions := newCSR.Status.Conditions
    
    	// Updating the approval should only update the conditions.
    	newCSR.Spec = oldCSR.Spec
    	newCSR.Status = oldCSR.Status
    	newCSR.Status.Conditions = newConditions
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Mar 18 21:41:43 UTC 2022
    - 11.4K bytes
    - Viewed (0)
  8. src/runtime/slice.go

    		// gives a smooth-ish transition between the two.
    		newcap += (newcap + 3*threshold) >> 2
    
    		// We need to check `newcap >= newLen` and whether `newcap` overflowed.
    		// newLen is guaranteed to be larger than zero, hence
    		// when newcap overflows then `uint(newcap) > uint(newLen)`.
    		// This allows to check for both with the same comparison.
    		if uint(newcap) >= uint(newLen) {
    			break
    		}
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 16:25:21 UTC 2024
    - 12.2K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/lite/transforms/modify_io_nodes.cc

            arg_type = quantize_output.getType();
            new_arg = block.addArgument(arg_type, loc);
            quantize_output.replaceAllUsesWith(new_arg);
          } else if (input_type.isUnsignedInteger(
                         current_type.getIntOrFloatBitWidth())) {  // int8 != uint8
            arg_type = quant::ConvertSignedQuantizedToUnsigned(
                quantize_output.getType(), loc);
            new_arg = block.addArgument(arg_type, loc);
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 8.9K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/collect/BenchmarkHelpers.java

            checkState(newMap instanceof MapMakerInternalMap);
            newMap.putAll(map);
            return newMap;
          }
        },
        MapMakerWeakKeysStrongValues {
          @Override
          public <K extends Comparable<K>, V> Map<K, V> create(Map<K, V> map) {
            ConcurrentMap<K, V> newMap = new MapMaker().weakKeys().makeMap();
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Fri Mar 04 04:06:35 UTC 2022
    - 12.3K bytes
    - Viewed (0)
Back to top