Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 10 for nelem (0.08 sec)

  1. scan.go

    				if !update {
    					if !isPtr {
    						elem = elem.Elem()
    					}
    					if isArrayKind {
    						if reflectValue.Len() >= int(db.RowsAffected) {
    							reflectValue.Index(int(db.RowsAffected - 1)).Set(elem)
    						}
    					} else {
    						reflectValue = reflect.Append(reflectValue, elem)
    					}
    				}
    			}
    
    			if !update {
    				db.Statement.ReflectValue.Set(reflectValue)
    			}
    Registered: Wed Jun 12 16:27:09 UTC 2024
    - Last Modified: Wed Jun 12 10:57:36 UTC 2024
    - 10K bytes
    - Viewed (0)
  2. callbacks/preload.go

    	}
    
    	for i := 0; i < reflectResults.Len(); i++ {
    		elem := reflectResults.Index(i)
    		for idx, field := range relForeignFields {
    			fieldValues[idx], _ = field.ValueOf(tx.Statement.Context, elem)
    		}
    
    		datas, ok := identityMap[utils.ToStringKey(fieldValues...)]
    		if !ok {
    			return fmt.Errorf("failed to assign association %#v, make sure foreign fields exists", elem.Interface())
    		}
    
    		for _, data := range datas {
    Registered: Wed Jun 12 16:27:09 UTC 2024
    - Last Modified: Wed Jun 12 10:52:33 UTC 2024
    - 11.6K bytes
    - Viewed (0)
  3. staging/src/k8s.io/apiserver/pkg/storage/cacher/watch_cache.go

    		return fmt.Errorf("couldn't compute key: %v", err)
    	}
    	elem := &storeElement{Key: key, Object: event.Object}
    	elem.Labels, elem.Fields, err = w.getAttrsFunc(event.Object)
    	if err != nil {
    		return err
    	}
    
    	wcEvent := &watchCacheEvent{
    		Type:            event.Type,
    		Object:          elem.Object,
    		ObjLabels:       elem.Labels,
    		ObjFields:       elem.Fields,
    		Key:             key,
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jun 11 10:20:57 UTC 2024
    - 26.2K bytes
    - Viewed (0)
  4. src/go/types/unify.go

    			// assume they are the same to avoid spurious follow-on errors.
    			return (x.len < 0 || y.len < 0 || x.len == y.len) && u.nify(x.elem, y.elem, emode, p)
    		}
    
    	case *Slice:
    		// Two slice types unify if their element types unify.
    		if y, ok := y.(*Slice); ok {
    			return u.nify(x.elem, y.elem, emode, p)
    		}
    
    	case *Struct:
    		// Two struct types unify if they have the same sequence of fields,
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 11 16:24:39 UTC 2024
    - 27.9K bytes
    - Viewed (0)
  5. cmd/object-api-utils.go

    	}()
    
    	return pathJoinBuf(sb, elem...)
    }
    
    // pathJoinBuf - like path.Join() but retains trailing SlashSeparator of the last element.
    // Provide a string builder to reduce allocation.
    func pathJoinBuf(dst *bytebufferpool.ByteBuffer, elem ...string) string {
    	trailingSlash := len(elem) > 0 && hasSuffixByte(elem[len(elem)-1], SlashSeparatorChar)
    	dst.Reset()
    	added := 0
    	for _, e := range elem {
    		if added > 0 || e != "" {
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Tue Jun 11 03:13:30 UTC 2024
    - 36.3K bytes
    - Viewed (0)
  6. association.go

    			}
    
    			appendToFieldValues := func(ev reflect.Value) {
    				if ev.Type().AssignableTo(elemType) {
    					fieldValue = reflect.Append(fieldValue, ev)
    				} else if ev.Type().Elem().AssignableTo(elemType) {
    					fieldValue = reflect.Append(fieldValue, ev.Elem())
    				} else {
    					association.Error = fmt.Errorf("unsupported data type: %v for relation %s", ev.Type(), association.Relationship.Name)
    				}
    
    Registered: Wed Jun 12 16:27:09 UTC 2024
    - Last Modified: Wed Jun 12 10:49:45 UTC 2024
    - 21.5K bytes
    - Viewed (0)
  7. src/cmd/compile/internal/types2/unify.go

    			// assume they are the same to avoid spurious follow-on errors.
    			return (x.len < 0 || y.len < 0 || x.len == y.len) && u.nify(x.elem, y.elem, emode, p)
    		}
    
    	case *Slice:
    		// Two slice types unify if their element types unify.
    		if y, ok := y.(*Slice); ok {
    			return u.nify(x.elem, y.elem, emode, p)
    		}
    
    	case *Struct:
    		// Two struct types unify if they have the same sequence of fields,
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 11 16:24:39 UTC 2024
    - 27.8K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tensorflow/utils/tpu_rewrite_device_util.cc

      return parsed_device.has_type && parsed_device.type == kTPUReplicatedCore;
    }
    
    bool TypeValidForXLA(const mlir::Type& type) {
      const mlir::Type elem = getElementTypeOrSelf(type);
      return !mlir::isa<mlir::TF::ResourceType>(elem) &&
             !mlir::isa<mlir::TF::StringType>(elem);
    }
    
    mlir::LogicalResult GetDeviceToHostMap(
        mlir::tf_device::ClusterOp cluster,
        llvm::SmallVector<std::string, 8>& core_to_host) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Mon Jun 10 20:10:40 UTC 2024
    - 32.8K bytes
    - Viewed (0)
  9. callbacks/query.go

    				switch db.Statement.ReflectValue.Kind() {
    				case reflect.Struct:
    					queryFields = db.Statement.ReflectValue.Type() != db.Statement.Schema.ModelType
    				case reflect.Slice:
    					queryFields = db.Statement.ReflectValue.Type().Elem() != db.Statement.Schema.ModelType
    				}
    			}
    
    			if queryFields {
    				stmt := gorm.Statement{DB: db}
    				// smaller struct
    Registered: Wed Jun 12 16:27:09 UTC 2024
    - Last Modified: Wed Jun 12 09:51:44 UTC 2024
    - 10.1K bytes
    - Viewed (0)
  10. src/cmd/compile/internal/ssa/func.go

    	d := f.SplitSlot(name, ".data", u.Size(), t)
    	return c, d
    }
    
    func (f *Func) SplitSlice(name *LocalSlot) (*LocalSlot, *LocalSlot, *LocalSlot) {
    	ptrType := types.NewPtr(name.Type.Elem())
    	lenType := types.Types[types.TINT]
    	p := f.SplitSlot(name, ".ptr", 0, ptrType)
    	l := f.SplitSlot(name, ".len", ptrType.Size(), lenType)
    	c := f.SplitSlot(name, ".cap", ptrType.Size()+lenType.Size(), lenType)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 10 19:44:43 UTC 2024
    - 25.8K bytes
    - Viewed (0)
Back to top