Search Options

Results per page
Sort
Preferred Languages
Advance

Results 61 - 70 of 1,740 for REFLECT (0.12 sec)

  1. test/escape_unsafe.go

    	return unsafe.Pointer(reflect.ValueOf(p).Elem().UnsafeAddr())
    }
    
    // (6) Conversion of a reflect.SliceHeader or reflect.StringHeader
    // Data field to or from Pointer.
    
    func fromSliceData(s []int) unsafe.Pointer { // ERROR "leaking param: s to result ~r0 level=0$"
    	return unsafe.Pointer((*reflect.SliceHeader)(unsafe.Pointer(&s)).Data)
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Sep 07 17:25:59 UTC 2022
    - 2.2K bytes
    - Viewed (0)
  2. pkg/printers/tablegenerator.go

    func (h *HumanReadableGenerator) GenerateTable(obj runtime.Object, options GenerateOptions) (*metav1.Table, error) {
    	t := reflect.TypeOf(obj)
    	handler, ok := h.handlerMap[t]
    	if !ok {
    		return nil, fmt.Errorf("no table handler registered for this type %v", t)
    	}
    
    	args := []reflect.Value{reflect.ValueOf(obj), reflect.ValueOf(options)}
    	results := handler.printFunc.Call(args)
    	if !results[1].IsNil() {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jul 26 17:14:05 UTC 2022
    - 5.9K bytes
    - Viewed (0)
  3. platforms/core-runtime/base-asm/src/main/java/org/gradle/model/internal/asm/AsmClassGeneratorUtils.java

     */
    
    package org.gradle.model.internal.asm;
    
    import javax.annotation.Nonnull;
    import java.lang.reflect.Constructor;
    import java.lang.reflect.GenericArrayType;
    import java.lang.reflect.Method;
    import java.lang.reflect.ParameterizedType;
    import java.lang.reflect.Type;
    import java.lang.reflect.TypeVariable;
    import java.lang.reflect.WildcardType;
    
    import static org.objectweb.asm.Type.getType;
    
    public class AsmClassGeneratorUtils {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue Apr 02 15:31:25 UTC 2024
    - 7K bytes
    - Viewed (0)
  4. test/fixedbugs/issue27695c.go

    func (t *T) Foo(e error) error {
    	runtime.GC()
    	return e
    }
    
    func main() {
    	// Functions
    	d := reflect.MakeFunc(reflect.TypeOf(func(e error) error { return e }),
    		func(args []reflect.Value) []reflect.Value {
    			runtime.GC()
    			return args
    		}).Interface().(func(error) error)
    	f(d)
    
    	// Methods
    	x := reflect.ValueOf(&T{}).Method(0).Interface().(func(error) error)
    	f(x)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Nov 13 22:52:09 UTC 2018
    - 1.3K bytes
    - Viewed (0)
  5. schema/callbacks_test.go

    	}
    
    	for _, str := range []string{"BeforeSave", "AfterCreate"} {
    		if !reflect.Indirect(reflect.ValueOf(user)).FieldByName(str).Interface().(bool) {
    			t.Errorf("%v should be true", str)
    		}
    	}
    
    	for _, str := range []string{"BeforeCreate", "BeforeUpdate", "AfterUpdate", "AfterSave", "BeforeDelete", "AfterDelete", "AfterFind"} {
    		if reflect.Indirect(reflect.ValueOf(user)).FieldByName(str).Interface().(bool) {
    Registered: Wed Jun 12 16:27:09 UTC 2024
    - Last Modified: Thu Jan 06 07:02:53 UTC 2022
    - 939 bytes
    - Viewed (0)
  6. src/encoding/xml/typeinfo.go

    // returns a zero reflect.Value.
    func (finfo *fieldInfo) value(v reflect.Value, shouldInitNilPointers bool) reflect.Value {
    	for i, x := range finfo.idx {
    		if i > 0 {
    			t := v.Type()
    			if t.Kind() == reflect.Pointer && t.Elem().Kind() == reflect.Struct {
    				if v.IsNil() {
    					if !shouldInitNilPointers {
    						return reflect.Value{}
    					}
    					v.Set(reflect.New(v.Type().Elem()))
    				}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Aug 07 00:23:29 UTC 2023
    - 9.6K bytes
    - Viewed (0)
  7. platforms/core-configuration/kotlin-dsl/src/test/kotlin/org/gradle/kotlin/dsl/integration/GradleApiParameterNamesTest.kt

    import org.gradle.kotlin.dsl.PluginDependenciesSpecScope
    
    import org.hamcrest.CoreMatchers.equalTo
    import org.hamcrest.MatcherAssert.assertThat
    import org.junit.Test
    
    import kotlin.reflect.KClass
    import kotlin.reflect.full.declaredFunctions
    import kotlin.reflect.full.valueParameters
    
    
    class GradleApiParameterNamesTest {
    
        @Test
        fun `Kotlin delegation generated member has parameter names`() {
    
            assertHasParameterNames(
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Wed Aug 02 08:06:49 UTC 2023
    - 2.1K bytes
    - Viewed (0)
  8. src/vendor/golang.org/x/crypto/internal/alias/alias_purego.go

    // This is the Google App Engine standard variant based on reflect
    // because the unsafe package and cgo are disallowed.
    
    import "reflect"
    
    // AnyOverlap reports whether x and y share memory at any (not necessarily
    // corresponding) index. The memory beyond the slice length is ignored.
    func AnyOverlap(x, y []byte) bool {
    	return len(x) > 0 && len(y) > 0 &&
    		reflect.ValueOf(&x[0]).Pointer() <= reflect.ValueOf(&y[len(y)-1]).Pointer() &&
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 23:33:33 UTC 2023
    - 1.2K bytes
    - Viewed (0)
  9. test/fixedbugs/issue32901.dir/main.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package main
    
    import (
    	"reflect"
    
    	"./c"
    )
    
    func main() {
    	x := c.F()
    	p := c.P()
    	t := reflect.PointerTo(reflect.TypeOf(x))
    	tp := reflect.TypeOf(p)
    	if t != tp {
    		panic("FAIL")
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Oct 26 14:24:17 UTC 2021
    - 346 bytes
    - Viewed (0)
  10. clause/expression.go

    		case map[string]interface{}:
    			for k, v := range value {
    				namedMap[k] = v
    			}
    		default:
    			var appendFieldsToMap func(reflect.Value)
    			appendFieldsToMap = func(reflectValue reflect.Value) {
    				reflectValue = reflect.Indirect(reflectValue)
    				switch reflectValue.Kind() {
    				case reflect.Struct:
    					modelType := reflectValue.Type()
    					for i := 0; i < modelType.NumField(); i++ {
    Registered: Wed Jun 12 16:27:09 UTC 2024
    - Last Modified: Tue Oct 10 06:45:48 UTC 2023
    - 8.3K bytes
    - Viewed (0)
Back to top