MCPcopy Create free account
hub / github.com/nsf/gocode / parse_package

Method parse_package

package_text.go:161–168  ·  view source on GitHub ↗

ImportPath = string_lit . quoted name of the path, but we return it as an identifier, taking an alias from 'pathToAlias' map, it is filled by import statements

()

Source from the content-addressed store, hash-verified

159// quoted name of the path, but we return it as an identifier, taking an alias
160// from 'pathToAlias' map, it is filled by import statements
161func (p *gc_parser) parse_package() *ast.Ident {
162 path, err := strconv.Unquote(p.expect(scanner.String))
163 if err != nil {
164 panic(err)
165 }
166
167 return ast.NewIdent(path)
168}
169
170// ExportedName = "@" ImportPath "." dotIdentifier .
171func (p *gc_parser) parse_exported_name() *ast.SelectorExpr {

Callers 2

parse_exported_nameMethod · 0.95
parse_import_declMethod · 0.95

Calls 1

expectMethod · 0.95

Tested by

no test coverage detected