v0.0.0-...-2824937 Latest Latest

This package is not in the latest version of its module.

Go to latest
Published: Nov 2, 2020 License: MIT, BSD-3-Clause Imports: 17 Imported by: 0



Package gccgoimporter implements Import for gccgo-generated object files.



This section is empty.


This section is empty.


func GetImporter

func GetImporter(searchpaths []string, initmap map[*types.Package]InitData) types.Importer


type GccgoInstallation

type GccgoInstallation struct {
	// Version of gcc (e.g. 4.8.0).
	GccVersion string

	// Target triple (e.g. x86_64-unknown-linux-gnu).
	TargetTriple string

	// Built-in library paths used by this installation.
	LibPaths []string

Information about a specific installation of gccgo.

func (*GccgoInstallation) GetImporter

func (inst *GccgoInstallation) GetImporter(incpaths []string, initmap map[*types.Package]InitData) types.Importer

Return an importer that searches incpaths followed by the gcc installation's built-in search paths and the current directory.

func (*GccgoInstallation) InitFromDriver

func (inst *GccgoInstallation) InitFromDriver(gccgoPath string) (err error)

Ask the driver at the given path for information for this GccgoInstallation.

func (*GccgoInstallation) SearchPaths

func (inst *GccgoInstallation) SearchPaths() (paths []string)

Return the list of export search paths for this GccgoInstallation.

type InitData

type InitData struct {
	// Initialization priority of this package relative to other packages.
	// This is based on the maximum depth of the package's dependency graph;
	// it is guaranteed to be greater than that of its dependencies.
	Priority int

	// The list of packages which this package depends on to be initialized,
	// including itself if needed. This is the subset of the transitive closure of
	// the package's dependencies that need initialization.
	Inits []PackageInit

The gccgo-specific init data for a package.

type PackageInit

type PackageInit struct {
	Name     string // short package name
	InitFunc string // name of init function
	Priority int    // priority of init function, see InitData.Priority

A PackageInit describes an imported package that needs initialization.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL