You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
package common
|
|
|
|
func uint16ToBytes(n uint16) []byte {
|
|
return []byte{byte(n), byte(n >> 8)}
|
|
}
|
|
|
|
func uint32ToBytes(n uint32) []byte {
|
|
return []byte{byte(n), byte(n >> 8), byte(n >> 16), byte(n >> 24)}
|
|
}
|