gotools/internal/gcimporter/iimport.go

type intReader

func (r *intReader) int64() int64 {}

func (r *intReader) uint64() uint64 {}

const iexportVersionGo1_11

const iexportVersionPosCol

const iexportVersionGo1_18

const iexportVersionGenerics

const iexportVersion

const iexportVersionCurrent

type ident

const predeclReserved

type itag

const definedType

const pointerType

const sliceType

const arrayType

const chanType

const mapType

const signatureType

const structType

const interfaceType

const typeParamType

const instanceType

const unionType

const aliasType

const varTag

const funcTag

const genericFuncTag

const constTag

const aliasTag

const genericAliasTag

const typeParamTag

const typeTag

const genericTypeTag

// IImportData imports a package from the serialized package data
// and returns 0 and a reference to the package.
// If the export data version is not recognized or the format is otherwise
// compromised, an error is returned.
func IImportData(fset *token.FileSet, imports map[string]*types.Package, data []byte, path string) (int, *types.Package, error) {}

// IImportBundle imports a set of packages from the serialized package bundle.
func IImportBundle(fset *token.FileSet, imports map[string]*types.Package, data []byte) ([]*types.Package, error) {}

type GetPackagesFunc

type GetPackagesItem

// GetPackagesFromMap returns a GetPackagesFunc that retrieves
// packages from the given map of package path to package.
//
// The returned function may mutate m: each requested package that is not
// found is created with types.NewPackage and inserted into m.
func GetPackagesFromMap(m map[string]*types.Package) GetPackagesFunc {}

func iimportCommon(fset *token.FileSet, getPackages GetPackagesFunc, data []byte, bundle bool, path string, shallow bool, reportf ReportFunc) (pkgs []*types.Package, err error) {}

type setConstraintArgs

type iimporter

func (p *iimporter) trace(format string, args ...interface{}

func (p *iimporter) doDecl(pkg *types.Package, name string) {}

func (p *iimporter) stringAt(off uint64) string {}

func (p *iimporter) fileAt(index uint64) *token.File {}

func (p *iimporter) decodeFile(rd intReader) *token.File {}

func (p *iimporter) pkgAt(off uint64) *types.Package {}

func (p *iimporter) typAt(off uint64, base *types.Named) types.Type {}

// canReuse reports whether the type rhs on the RHS of the declaration for def
// may be re-used.
//
// Specifically, if def is non-nil and rhs is an interface type with methods, it
// may not be re-used because we have a convention of setting the receiver type
// for interface methods to def.
func canReuse(def *types.Named, rhs types.Type) bool {}

type importReader

var markBlack

func (r *importReader) obj(name string) {}

func (r *importReader) declare(obj types.Object) {}

func (r *importReader) value() (typ types.Type, val constant.Value) {}

func intSize(b *types.Basic) (signed bool, maxBytes uint) {}

func (r *importReader) mpint(x *big.Int, typ *types.Basic) {}

func (r *importReader) mpfloat(typ *types.Basic) constant.Value {}

func (r *importReader) ident() string {}

func (r *importReader) qualifiedIdent() (*types.Package, string) {}

func (r *importReader) pos() token.Pos {}

func (r *importReader) posv0() {}

func (r *importReader) posv1() {}

func (r *importReader) posv2() token.Pos {}

func (r *importReader) typ() types.Type {}

func isInterface(t types.Type) bool {}

func (r *importReader) pkg() *types.Package {}

func (r *importReader) string() string      {}

func (r *importReader) doType(base *types.Named) (res types.Type) {}

func (r *importReader) kind() itag {}

// objectPathObject is the inverse of exportWriter.objectPath.
//
// In shallow mode, certain fields and methods may need to be looked up in an
// imported package. See the doc for exportWriter.objectPath for a full
// explanation.
func (r *importReader) objectPathObject() types.Object {}

func (r *importReader) signature(recv *types.Var, rparams []*types.TypeParam, tparams []*types.TypeParam) *types.Signature {}

func (r *importReader) tparamList() []*types.TypeParam {}

func (r *importReader) paramList() *types.Tuple {}

func (r *importReader) param() *types.Var {}

func (r *importReader) bool() bool {}

func (r *importReader) int64() int64 {}

func (r *importReader) uint64() uint64 {}

func (r *importReader) byte() byte {}