find all comment lines that begin with //msgp:
(c []*ast.CommentGroup)
| 67 | |
| 68 | // find all comment lines that begin with //msgp: |
| 69 | func yieldComments(c []*ast.CommentGroup) []string { |
| 70 | var out []string |
| 71 | for _, cg := range c { |
| 72 | for _, line := range cg.List { |
| 73 | if after, ok := strings.CutPrefix(line.Text, linePrefix); ok { |
| 74 | out = append(out, after) |
| 75 | } |
| 76 | } |
| 77 | } |
| 78 | return out |
| 79 | } |
| 80 | |
| 81 | //msgp:shim {Type} as:{NewType} using:{toFunc/fromFunc} mode:{Mode} |
| 82 | func applyShim(text []string, f *FileSet) error { |
no outgoing calls
no test coverage detected
searching dependent graphs…