MCPcopy Index your code
hub / github.com/tinygo-org/tinygo / getPackage

Method getPackage

builder/sizes.go:58–68  ·  view source on GitHub ↗

Return the package size information for a given package path, creating it if it doesn't exist yet.

(path string)

Source from the content-addressed store, hash-verified

56// Return the package size information for a given package path, creating it if
57// it doesn't exist yet.
58func (ps *programSize) getPackage(path string) *packageSize {
59 if field, ok := ps.Packages[path]; ok {
60 return field
61 }
62 field := &packageSize{
63 Program: ps,
64 Sub: map[string]*packageSize{},
65 }
66 ps.Packages[path] = field
67 return field
68}
69
70// packageSize contains the size of a package, calculated from the linked object
71// file.

Callers 2

loadProgramSizeFunction · 0.95
readSectionFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected