Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 449 for iota (0.04 sec)

  1. src/internal/types/testdata/check/const0.go

    		_p5 = assert(b3 == 42)
    	)
    }
    
    // iota
    const (
    	iota0 = iota
    	iota1 = iota
    	iota2 = iota*2
    	_a0 = assert(iota0 == 0)
    	_a1 = assert(iota1 == 1)
    	_a2 = assert(iota2 == 4)
    	iota6 = iota*3
    
    	iota7
    	iota8
    	_a3 = assert(iota7 == 21)
    	_a4 = assert(iota8 == 24)
    )
    
    const (
    	_b0 = iota
    	_b1 = assert(iota + iota2 == 5)
    	_b2 = len([iota]int{}) // iota may appear in a type!
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jan 17 19:54:25 UTC 2023
    - 9.2K bytes
    - Viewed (0)
  2. src/internal/types/testdata/check/constdecl.go

    const (
    	c = len([1 - iota]int{})
    	d
    	e // ERROR "invalid array length"
    	f // ERROR "invalid array length"
    )
    
    // Test that identifiers in implicit (omitted) RHS
    // expressions of constant declarations are resolved
    // in the correct context; see issues #49157, #53585.
    const X = 2
    
    func _() {
    	const (
    		A    = iota // 0
    		iota = iota // 1
    		B           // 1 (iota is declared locally on prev. line)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Oct 31 16:11:16 UTC 2023
    - 3.7K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/noder/codes.go

    const (
    	assignBlank codeAssign = iota
    	assignDef
    	assignExpr
    )
    
    // A codeDecl distinguishes among declaration encodings.
    type codeDecl int
    
    func (c codeDecl) Marker() pkgbits.SyncMarker { return pkgbits.SyncDecl }
    func (c codeDecl) Value() int                 { return int(c) }
    
    const (
    	declEnd codeDecl = iota
    	declFunc
    	declMethod
    	declVar
    	declOther
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Nov 15 20:07:46 UTC 2023
    - 1.9K bytes
    - Viewed (0)
  4. src/cmd/compile/internal/inline/inlheur/function_properties.go

    	// likewise.
    	FuncPropNeverReturns FuncPropBits = 1 << iota
    )
    
    type ParamPropBits uint32
    
    const (
    	// No info about this param
    	ParamNoInfo ParamPropBits = 0
    
    	// Parameter value feeds unmodified into a top-level interface
    	// call (this assumes the parameter is of interface type).
    	ParamFeedsInterfaceMethodCall ParamPropBits = 1 << iota
    
    	// Parameter value feeds unmodified into an interface call that
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Aug 10 18:52:53 UTC 2023
    - 3.7K bytes
    - Viewed (0)
  5. src/internal/pkgbits/reloc.go

    const (
    	PublicRootIdx  Index = 0
    	PrivateRootIdx Index = 1
    )
    
    const (
    	RelocString RelocKind = iota
    	RelocMeta
    	RelocPosBase
    	RelocPkg
    	RelocName
    	RelocType
    	RelocObj
    	RelocObjExt
    	RelocObjDict
    	RelocBody
    
    	numRelocs = iota
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Aug 10 22:22:48 UTC 2022
    - 835 bytes
    - Viewed (0)
  6. test/rename1.go

    // Does not compile.
    
    package main
    
    func main() {
    	var n byte         // ERROR "not a type|expected type"
    	var y = float32(0) // ERROR "cannot call|expected function"
    	const (
    		a = 1 + iota // ERROR "invalid operation|incompatible types|cannot convert"
    	)
    	_, _ = n, y
    }
    
    const (
    	append     = 1
    	bool       = 2
    	byte       = 3
    	complex    = 4
    	complex64  = 5
    	complex128 = 6
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 19 14:07:00 UTC 2023
    - 1.1K bytes
    - Viewed (0)
  7. src/cmd/internal/obj/wasm/a.out.go

    import "cmd/internal/obj"
    
    //go:generate go run ../stringer.go -i $GOFILE -o anames.go -p wasm
    
    const (
    	/* mark flags */
    	DONE          = 1 << iota
    	PRESERVEFLAGS // not allowed to clobber flags
    )
    
    /*
     *	wasm
     */
    const (
    	AGet = obj.ABaseWasm + obj.A_ARCHSPECIFIC + iota
    	ASet
    	ATee
    	ANot // alias for I32Eqz
    
    	// The following are low-level WebAssembly instructions.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 02 05:28:55 UTC 2023
    - 4.3K bytes
    - Viewed (0)
  8. src/cmd/internal/obj/arm64/a.out.go

    const (
    	BIG = 2048 - 8
    )
    
    const (
    	/* mark flags */
    	LABEL = 1 << iota
    	LEAF
    	FLOAT
    	BRANCH
    	LOAD
    	FCMP
    	SYNC
    	LIST
    	FOLL
    	NOSCHED
    )
    
    const (
    	// optab is sorted based on the order of these constants
    	// and the first match is chosen.
    	// The more specific class needs to come earlier.
    	C_NONE   = iota + 1 // starting from 1, leave unclassified Addr's class as 0
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Oct 18 17:56:30 UTC 2023
    - 18.1K bytes
    - Viewed (0)
  9. src/runtime/traceexp.go

    type traceExperiment uint8
    
    const (
    	// traceNoExperiment indicates no experiment.
    	traceNoExperiment traceExperiment = iota
    
    	// traceExperimentAllocFree is an experiment to add alloc/free events to the trace.
    	traceExperimentAllocFree
    )
    
    // Experimental events.
    const (
    	_ traceEv = 127 + iota
    
    	// Experimental events for ExperimentAllocFree.
    
    	// Experimental heap span events. IDs map reversibly to base addresses.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 08 17:47:01 UTC 2024
    - 2.4K bytes
    - Viewed (0)
  10. src/internal/pkgbits/flags.go

    // Copyright 2022 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 pkgbits
    
    const (
    	flagSyncMarkers = 1 << iota // file format contains sync markers
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jul 12 19:30:30 UTC 2022
    - 253 bytes
    - Viewed (0)
Back to top