MCPcopy Create free account
hub / github.com/cogentcore/core / SaveSymDoc

Function SaveSymDoc

parse/syms/cache.go:97–109  ·  view source on GitHub ↗

SaveSymDoc saves doc file of syms -- for double-checking contents etc

(sy *Symbol, lang fileinfo.Known, filename string)

Source from the content-addressed store, hash-verified

95
96// SaveSymDoc saves doc file of syms -- for double-checking contents etc
97func SaveSymDoc(sy *Symbol, lang fileinfo.Known, filename string) error {
98 cfile, err := CacheFilename(lang, filename)
99 if err != nil {
100 return err
101 }
102 cfile += ".doc"
103 ofl, err := os.Create(cfile)
104 if err != nil {
105 return err
106 }
107 sy.WriteDoc(ofl, 0)
108 return nil
109}
110
111// OpenSymCache opens cache of symbols into given symbol
112// (typically a package, module, library), which is at given

Callers 1

DoGoPathFunction · 0.92

Calls 3

CacheFilenameFunction · 0.85
CreateMethod · 0.80
WriteDocMethod · 0.45

Tested by

no test coverage detected