philpearl / plenc

Go encoding based on protobuf, but hopefully easier to deal with
MIT License
28 stars 2 forks source link

Can't deal with recursive struct definitions - causes stack overflow #4

Closed philpearl closed 2 years ago

philpearl commented 2 years ago

E.g.

type MyThing struct {
  Slice []MyThing `plenc:"1"`
}

Trying to marshal this causes a stack overflow recursively trying to build a codec for the MyThing struct