RewriteSource attempts to add trace-related code if needed. TODO: add support for multiple files and package selectors
()
| 132 | // RewriteSource attempts to add trace-related code if needed. |
| 133 | // TODO: add support for multiple files and package selectors |
| 134 | func (r *NativeRun) RewriteSource() error { |
| 135 | path, err := rewriteSource(r.OrigPath) |
| 136 | if err != nil { |
| 137 | return err |
| 138 | } |
| 139 | |
| 140 | r.Path = path |
| 141 | |
| 142 | return nil |
| 143 | } |
| 144 | |
| 145 | // RawSource implements EventSource for |
| 146 | // raw events in JSON file. |