On Sat, Oct 15, 2016 at 3:17 PM, Tong Sun wrote: > Hi, > > Need help again. > > I got everything tested out correctly, in https://github.com/suntong/ > lang/blob/master/lang/Go/src/ds/PersistentData-GOB.go, but when I tried > to apply it to my real case (more complicated data structure), it doesn't > work any more. I've put my code ... >
Having added error checking, I realized that the "more complicated data structure" that is causing me trouble saving it is golang-set, from github.com/deckarep/golang-set I've stripped the problematic code to https://github.com/suntong/lang/blob/052ca2ae5d6c713c5a7ee75146654dcde3a9e28e/lang/Go/src/ds/Set-Go_Perm.go which I'll get the following when I run: $ go run Set-Go_Perm.go 2016/10/22 12:48:54 SaveState failed:gob: type sync.RWMutex has no exported fields exit status 1 For my own code, it is another error, also caused by mapset from github.com/deckarep/golang-set: encode error:gob: type not registered for interface: mapset.threadSafeSet Is there any possibility to make gob to save an object embedded with mapset? This is vitally important to my program. Thanks -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.