From 31b0de9907679baa1116ec957306f6cfd6f1290e Mon Sep 17 00:00:00 2001 From: gonutz Date: Wed, 15 Feb 2023 09:32:14 +0100 Subject: [PATCH] Readme: make variable names in paragraphs the same I had to do a double take when reading the example where it said `Str` and the paragraph directly below where it said `StringField`. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e8c6f01..06d22f8 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,7 @@ type Example struct { Struct tag format ---- - - ```Var []int `struc:"[]int32,little,sizeof=StringField"` ``` will pack Var as a slice of little-endian int32, and link it as the size of `StringField`. + - ```Var []int `struc:"[]int32,little,sizeof=Str"` ``` will pack Var as a slice of little-endian int32, and link it as the size of the `Str` field. - `sizeof=`: Indicates this field is a number used to track the length of a another field. `sizeof` fields are automatically updated on `Pack()` based on the current length of the tracked field, and are used to size the target field during `Unpack()`. - Bare values will be parsed as type and endianness.