Registry / serialization / go-restruct-restruct

go-restruct-restruct

JSON →
library1.2.0-alphagogounverified

Package restruct implements packing and unpacking of raw binary formats.

go get github.com/go-restruct/restruct
INSTALL
IMPORT
SIG · GO-RESTRUCT-RESTRU
G
go-restruct-restruct
serializationgov1.2.0-alpha
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

restruct
github.com/go-restruct/restruct

Unpacks binary data into a struct using restruct.

package main import ( "fmt" "github.com/go-restruct/restruct" ) type MyStruct struct { A uint8 B uint16 } func main() { data := []byte{0x01, 0x02, 0x00} var s MyStruct err := restruct.Unpack(data, binary.LittleEndian, &s) if err != nil { panic(err) } fmt.Printf("%+v\n", s) }
Debug
Known issues
breakingAlpha version may have breaking changes
fix
Pin to a specific version and test thoroughly
affects: >=1.2.0-alpha
Upgrade
Version history
1.2.0-alphalatest on pkg.go.dev
Audit
Dependencies

No dependency data recorded yet.

Agent activity
4 hits · last 30 days
node
4
Resources
go-restruct-restruct — go get go-restruct-restruct · libregistry