mirror of
https://github.com/netbirdio/easyjson.git
synced 2026-05-22 18:44:42 -07:00
Merge pull request #41 from hectorj/temporary-file-marshal-no-pointer
Remove pointer-receivers for Marshalling funcs in bootstrap file
This commit is contained in:
@@ -59,11 +59,11 @@ func (g *Generator) writeStub() error {
|
||||
for _, t := range g.Types {
|
||||
fmt.Fprintln(f)
|
||||
if !g.NoStdMarshalers {
|
||||
fmt.Fprintln(f, "func (*", t, ") MarshalJSON() ([]byte, error) { return nil, nil }")
|
||||
fmt.Fprintln(f, "func (", t, ") MarshalJSON() ([]byte, error) { return nil, nil }")
|
||||
fmt.Fprintln(f, "func (*", t, ") UnmarshalJSON([]byte) error { return nil }")
|
||||
}
|
||||
|
||||
fmt.Fprintln(f, "func (*", t, ") MarshalEasyJSON(w *jwriter.Writer) {}")
|
||||
fmt.Fprintln(f, "func (", t, ") MarshalEasyJSON(w *jwriter.Writer) {}")
|
||||
fmt.Fprintln(f, "func (*", t, ") UnmarshalEasyJSON(l *jlexer.Lexer) {}")
|
||||
fmt.Fprintln(f)
|
||||
fmt.Fprintln(f, "type EasyJSON_exporter_"+t+" *"+t)
|
||||
|
||||
Reference in New Issue
Block a user