Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for ToInterface (0.51 sec)

  1. src/internal/reflectlite/all_test.go

    	. "internal/reflectlite"
    	"math"
    	"reflect"
    	"runtime"
    	"testing"
    	"unsafe"
    )
    
    func ToValue(v Value) reflect.Value {
    	return reflect.ValueOf(ToInterface(v))
    }
    
    func TypeString(t Type) string {
    	return fmt.Sprintf("%T", ToInterface(Zero(t)))
    }
    
    type integer int
    type T struct {
    	a int
    	b float64
    	c string
    	d *int
    }
    
    type pair struct {
    	i any
    	s string
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Nov 16 19:26:08 UTC 2023
    - 24.2K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/typecheck/subr.go

    		return ""
    	}
    
    	if isptrto(t, types.TINTER) {
    		return fmt.Sprintf("%v is pointer to interface, not interface", t)
    	} else if have != nil && have.Sym == missing.Sym && have.Nointerface() {
    		return fmt.Sprintf("%v does not implement %v (%v method is marked 'nointerface')", t, iface, missing.Sym)
    	} else if have != nil && have.Sym == missing.Sym {
    		return fmt.Sprintf("%v does not implement %v (wrong type for %v method)\n"+
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 05 19:45:58 UTC 2023
    - 20.2K bytes
    - Viewed (0)
  3. src/go/internal/gccgoimporter/parser.go

    		}
    	}
    
    	if p.tok == '\n' {
    		p.next()
    		// collect associated methods
    		for p.tok == scanner.Ident {
    			p.expectKeyword("func")
    			if p.tok == '/' {
    				// Skip a /*nointerface*/ or /*asm ID */ comment.
    				p.expect('/')
    				p.expect('*')
    				if p.expect(scanner.Ident) == "asm" {
    					p.parseUnquotedString()
    				}
    				p.expect('*')
    				p.expect('/')
    			}
    			p.expect('(')
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Feb 02 23:14:07 UTC 2024
    - 31.2K bytes
    - Viewed (0)
Back to top