Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for TestStructOfEmbeddedIfaceMethodCall (3.5 sec)

  1. src/reflect/type_test.go

    	}
    	for _, tc := range testcases {
    		want := reflect.ValueOf(tc.wantFrom).Elem().Type()
    		if want != tc.got {
    			t.Errorf("unexpected reflect.Type: got %v; want %v", tc.got, want)
    		}
    	}
    }
    
    func TestStructOfEmbeddedIfaceMethodCall(t *testing.T) {
    	type Named interface {
    		Name() string
    	}
    
    	typ := reflect.StructOf([]reflect.StructField{
    		{
    			Anonymous: true,
    			Name:      "Named",
    			Type:      reflect.TypeFor[Named](),
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 23:39:44 UTC 2024
    - 4.2K bytes
    - Viewed (0)
Back to top