Documentation
¶
Overview ¶
Package symbolassert asserts that symbols are defined in a package.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Errors ¶
type Errors struct {
Errs []error
}
Errors is returned from SymbolMap.Resolve and Compare.
type ObjectMap ¶
A ObjectMap maps from the locally defined symbol value to a value that is authoritative.
type PackageProvider ¶
type PackageProvider struct {
GOOS string // target operating system
GOARCH string // target architecture
BuildTags []string // build tags
// Package is used to resolve an unqualified identifier,
// an identifier without a package name. The caller is
// responsible to Load this package.
Package string
// contains filtered or unexported fields
}
func (*PackageProvider) Load ¶
func (p *PackageProvider) Load(path string) error
Load implements the Provider interface.
type Provider ¶
type Provider interface {
// Load loads the package at the given import path
// and makes the symbols available for lookup.
Load(importPath string) error
// Lookup looks up a symbol.
// It must return nil if not found.
Lookup(symbol string) types.Object
}
Provider looks up symbol names.
type SymbolMap ¶
A SymbolMap maps from a locally defined identifier to an identifier that is authoritative. The package name may be omitted.
type UnresolvedError ¶
UnresolvedError is returned if Resolve can't lookup a symbol.
func (*UnresolvedError) Error ¶
func (e *UnresolvedError) Error() string
Directories
¶
| Path | Synopsis |
|---|---|
|
internal
|
|
|
packageloader
Package packageloader provides helpers for loading packages.
|
Package packageloader provides helpers for loading packages. |
Click to show internal directories.
Click to hide internal directories.