FAQ

Of course I can encode everything to a string, then work with those, but
it's messy. I'd much rather find a way to manage it using bitsets as the
map keys.
It is a shame that you can't define a custom hash and equality function for
types based on slices, but I suppose immutability plays a part in that
argument...

Strings aren't so bad, especially if you make use of big.Int to do all the
encoding and decoding for you:

http://play.golang.org/p/jFKFAijpBO

Hope that helps,
Donovan.

--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group, send email to golang-nuts+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Search Discussions

Discussion Posts

Previous

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 2 of 3 | next ›
Discussion Overview
groupgolang-nuts @
categoriesgo
postedJan 28, '13 at 5:05a
activeJan 28, '13 at 10:47a
posts3
users2
websitegolang.org

2 users in discussion

Donovan Hide: 2 posts Craig Mason-Jones: 1 post

People

Translate

site design / logo © 2021 Grokbase