Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for TestQualifiedTypeString (0.28 sec)

  1. src/go/types/typestring_test.go

    			continue
    		}
    		typ := obj.Type().Underlying()
    		if got := typ.String(); got != test.str {
    			t.Errorf("%s: got %s, want %s", test.src, got, test.str)
    		}
    	}
    }
    
    func TestQualifiedTypeString(t *testing.T) {
    	p := mustTypecheck("package p; type T int", nil, nil)
    	q := mustTypecheck("package q", nil, nil)
    
    	pT := p.Scope().Lookup("T").Type()
    	for _, test := range []struct {
    		typ  Type
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 28 17:58:07 UTC 2023
    - 3.9K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/types2/typestring_test.go

    			continue
    		}
    		typ := obj.Type().Underlying()
    		if got := typ.String(); got != test.str {
    			t.Errorf("%s: got %s, want %s", test.src, got, test.str)
    		}
    	}
    }
    
    func TestQualifiedTypeString(t *testing.T) {
    	p := mustTypecheck("package p; type T int", nil, nil)
    	q := mustTypecheck("package q", nil, nil)
    
    	pT := p.Scope().Lookup("T").Type()
    	for _, test := range []struct {
    		typ  Type
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 28 17:58:07 UTC 2023
    - 3.9K bytes
    - Viewed (0)
Back to top