Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

encoding/gob: panic encoding slice of nil valued *big.Ints #5305

Closed
karalabe opened this issue Apr 17, 2013 · 3 comments
Closed

encoding/gob: panic encoding slice of nil valued *big.Ints #5305

karalabe opened this issue Apr 17, 2013 · 3 comments
Milestone

Comments

@karalabe
Copy link
Contributor

What steps will reproduce the problem?
Run Simply run on the site: http://play.golang.org/p/pz_E3cQ0_j

What is the expected output?
An encoded slice of nil values.

What do you see instead?
A panic :P

Which compiler are you using (5g, 6g, 8g, gccgo)?
Doesn't matter, crashes everywhere (see play link).

Please provide any additional information below.

If I encode a nil *big.Int, it works.
If I encode a slice of *string-s, each nil, it works.
If I encode a slice of *big.Int-s, each nil, it panics.

The full discussion thread on golang-nuts:
https://groups.google.com/group/golang-nuts/browse_thread/thread/ca0622c1c7f3242
@bradfitz
Copy link
Contributor

Comment 1:

Owner changed to @robpike.

Status changed to Accepted.

@rsc
Copy link
Contributor

rsc commented Jul 30, 2013

Comment 2:

Labels changed: added priority-later, go1.2maybe, removed priority-triage.

@robpike
Copy link
Contributor

robpike commented Aug 20, 2013

Comment 3:

Fixed by https://golang.org/cl/13042044

Status changed to Fixed.

@rsc rsc added this to the Go1.2 milestone Apr 14, 2015
@rsc rsc removed the go1.2maybe label Apr 14, 2015
@golang golang locked and limited conversation to collaborators Jun 24, 2016
@rsc rsc unassigned robpike Jun 22, 2022
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants