go/src/cmd/compile/internal/types2/check.go

var nopos

const debug

var _aliasAny

func aliasAny() bool {}

type exprInfo

type environment

// lookupScope looks up name in the current environment and if an object
// is found it returns the scope containing the object and the object.
// Otherwise it returns (nil, nil).
//
// Note that obj.Parent() may be different from the returned scope if the
// object was inserted into the scope and already had a parent at that
// time (see Scope.Insert). This can only happen for dot-imported objects
// whose parent is the scope of the package that exported them.
func (env *environment) lookupScope(name string) (*Scope, Object) {}

// lookup is like lookupScope but it only returns the object (or nil).
func (env *environment) lookup(name string) Object {}

type importKey

type dotImportKey

type action

// If debug is set, describef sets a printf-formatted description for action a.
// Otherwise, it is a no-op.
func (a *action) describef(pos poser, format string, args ...interface{}

type actionDesc

type Checker

// addDeclDep adds the dependency edge (check.decl -> to) if check.decl exists
func (check *Checker) addDeclDep(to Object) {}

// brokenAlias records that alias doesn't have a determined type yet.
// It also sets alias.typ to Typ[Invalid].
// Not used if check.conf.EnableAlias is set.
func (check *Checker) brokenAlias(alias *TypeName) {}

// validAlias records that alias has the valid type typ (possibly Typ[Invalid]).
func (check *Checker) validAlias(alias *TypeName, typ Type) {}

// isBrokenAlias reports whether alias doesn't have a determined type yet.
func (check *Checker) isBrokenAlias(alias *TypeName) bool {}

func (check *Checker) rememberUntyped(e syntax.Expr, lhs bool, mode operandMode, typ *Basic, val constant.Value) {}

// later pushes f on to the stack of actions that will be processed later;
// either at the end of the current statement, or in case of a local constant
// or variable declaration, before the constant or variable is in scope
// (so that f still sees the scope before any new declarations).
// later returns the pushed action so one can provide a description
// via action.describef for debugging, if desired.
func (check *Checker) later(f func()) *action {}

// push pushes obj onto the object path and returns its index in the path.
func (check *Checker) push(obj Object) int {}

// pop pops and returns the topmost object from the object path.
func (check *Checker) pop() Object {}

type cleaner

// needsCleanup records objects/types that implement the cleanup method
// which will be called at the end of type-checking.
func (check *Checker) needsCleanup(c cleaner) {}

// NewChecker returns a new Checker instance for a given package.
// Package files may be added incrementally via checker.Files.
func NewChecker(conf *Config, pkg *Package, info *Info) *Checker {}

// initFiles initializes the files-specific portion of checker.
// The provided files must all belong to the same package.
func (check *Checker) initFiles(files []*syntax.File) {}

func versionMax(a, b goVersion) goVersion {}

type bailout

func (check *Checker) handleBailout(err *error) {}

// Files checks the provided files as part of the checker's package.
func (check *Checker) Files(files []*syntax.File) (err error) {}

// checkFiles type-checks the specified files. Errors are reported as
// a side effect, not by returning early, to ensure that well-formed
// syntax is properly type annotated even in a package containing
// errors.
func (check *Checker) checkFiles(files []*syntax.File) {}

// processDelayed processes all delayed actions pushed after top.
func (check *Checker) processDelayed(top int) {}

// cleanup runs cleanup for all collected cleaners.
func (check *Checker) cleanup() {}

// types2-specific support for recording type information in the syntax tree.
func (check *Checker) recordTypeAndValueInSyntax(x syntax.Expr, mode operandMode, typ Type, val constant.Value) {}

// types2-specific support for recording type information in the syntax tree.
func (check *Checker) recordCommaOkTypesInSyntax(x syntax.Expr, t0, t1 Type) {}

// instantiatedIdent determines the identifier of the type instantiated in expr.
// Helper function for recordInstance in recording.go.
func instantiatedIdent(expr syntax.Expr) *syntax.Name {}