Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 2,877 for types2 (0.1 sec)

  1. src/cmd/compile/internal/types2/sizes_test.go

    const _ = unsafe.Offsetof(struct{ x int64 }{}.x)
    `
    	info := types2.Info{Types: make(map[syntax.Expr]types2.TypeAndValue)}
    	conf := types2.Config{
    		Importer: defaultImporter(),
    		Sizes:    &types2.StdSizes{WordSize: 8, MaxAlign: 8},
    	}
    	mustTypecheck(src, &conf, &info)
    	for _, tv := range info.Types {
    		_ = conf.Sizes.Sizeof(tv.Type)
    		_ = conf.Sizes.Alignof(tv.Type)
    	}
    }
    
    // go.dev/issue/53884.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Aug 16 21:00:48 UTC 2023
    - 4.1K bytes
    - Viewed (0)
  2. src/cmd/compile/internal/types2/example_test.go

    		return x
    	}
    	return fib(x-1) - fib(x-2)
    }`
    	// Type-check the package.
    	// We create an empty map for each kind of input
    	// we're interested in, and Check populates them.
    	info := types2.Info{
    		Types: make(map[syntax.Expr]types2.TypeAndValue),
    		Defs:  make(map[*syntax.Name]types2.Object),
    		Uses:  make(map[*syntax.Name]types2.Object),
    	}
    	pkg := mustTypecheck(input, nil, &info)
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 28 17:58:07 UTC 2023
    - 7.1K bytes
    - Viewed (0)
  3. src/cmd/compile/internal/types2/importer_test.go

    	gcimporter "cmd/compile/internal/importer"
    	"cmd/compile/internal/types2"
    	"io"
    )
    
    func defaultImporter() types2.Importer {
    	return &gcimports{
    		packages: make(map[string]*types2.Package),
    	}
    }
    
    type gcimports struct {
    	packages map[string]*types2.Package
    	lookup   func(path string) (io.ReadCloser, error)
    }
    
    func (m *gcimports) Import(path string) (*types2.Package, error) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 25 19:24:25 UTC 2021
    - 913 bytes
    - Viewed (0)
  4. platforms/ide/tooling-api/src/test/groovy/org/gradle/tooling/internal/adapter/TypeInspectorTest.groovy

            types == [Parent, Child] as Set
    
            def types2 = inspector.getReachableTypes(Child)
            types2 == types
        }
    
        def "inspects cyclic generic types"() {
            expect:
            def types = inspector.getReachableTypes(GenericChild)
            types == [GenericItem1, GenericItem2, GenericChild] as Set
    
            def types2 = inspector.getReachableTypes(GenericChild)
            types2.is(types)
        }
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue Sep 26 14:49:20 UTC 2023
    - 1.7K bytes
    - Viewed (0)
  5. src/cmd/cgo/internal/testerrors/testdata/err2.go

    	_ = func(i int) int {
    		// typecheck reports at column 14 ('+'), but types2 reports at
    		// column 10 ('C').
    		// TODO(mdempsky): Investigate why, and see if types2 can be
    		// updated to match typecheck behavior.
    		return C.i + 1 // ERROR HERE: \b(10|14)\b
    	}
    	_ = func(i int) {
    		// typecheck reports at column 7 ('('), but types2 reports at
    		// column 8 ('i'). The types2 position is more correct, but
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 12 11:59:56 UTC 2023
    - 2.5K bytes
    - Viewed (0)
  6. src/cmd/compile/internal/syntax/type.go

    package syntax
    
    import "go/constant"
    
    // A Type represents a type of Go.
    // All types implement the Type interface.
    // (This type originally lived in types2. We moved it here
    // so we could depend on it from other packages without
    // introducing an import cycle.)
    type Type interface {
    	// Underlying returns the underlying type of a type.
    	// Underlying types are never Named, TypeParam, or Alias types.
    	//
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 20:03:31 UTC 2024
    - 2.7K bytes
    - Viewed (0)
  7. src/cmd/compile/internal/types2/type.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package types2
    
    import "cmd/compile/internal/syntax"
    
    // A Type represents a type of Go.
    // All types implement the Type interface.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jan 17 19:55:41 UTC 2023
    - 316 bytes
    - Viewed (0)
  8. src/cmd/compile/internal/types2/util.go

    // This file contains various functionality that is
    // different between go/types and types2. Factoring
    // out this code allows more of the rest of the code
    // to be shared.
    
    package types2
    
    import (
    	"cmd/compile/internal/syntax"
    	"go/constant"
    	"go/token"
    )
    
    const isTypes2 = true
    
    // cmpPos compares the positions p and q and returns a result r as follows:
    //
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 03:01:18 UTC 2024
    - 2.1K bytes
    - Viewed (0)
  9. src/go/types/util_test.go

    // Source: ../../cmd/compile/internal/types2/util_test.go
    
    // Copyright 2023 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.
    
    // This file exports various functionality of util.go
    // so that it can be used in (package-external) tests.
    
    package types
    
    import (
    	"go/token"
    )
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 03 18:48:38 UTC 2024
    - 626 bytes
    - Viewed (0)
  10. src/internal/types/testdata/fixedbugs/issue46404.go

    // license that can be found in the LICENSE file.
    
    package issue46404
    
    // TODO(gri) re-enable this test with matching errors
    //           between go/types and types2
    // Check that we don't type check t[_] as an instantiation.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Sep 02 02:58:32 UTC 2022
    - 429 bytes
    - Viewed (0)
Back to top