Having a slice of uint8 but knowing that the uints are all smaller than 8: is there a simple way to en-/decode into a compact type using 3 bits a uint?
Only thing I can come up with is a complicated way of building a byte slice.
Having a slice of uint8 but knowing that the uints are all smaller than 8: is there a simple way to en-/decode into a compact type using 3 bits a uint?
Only thing I can come up with is a complicated way of building a byte slice.
收起
微信扫一扫报告相同问题?