gennyble / hext

A Binary File Markup Language
ISC License
23 stars 0 forks source link

implicitly sized decimal #13

Open gennyble opened 2 years ago

gennyble commented 2 years ago

Currently you may do =63 and or =601 and it'll use the smallest integer that it can that's still in octets. So 63'd be a u8 and 601 a u16. In talking about hext with someone during an interview, they raised a good point: that is not what you may expect for a binary format. Should we make it so using decimal without a size is a syntax error? Set a default size, but explicitly in the header? Should it error if it overflows?

gennyble commented 2 years ago

We could always assume them to be bytes. That seems like a fine solution? Why assume at all though? We'll sleep on it,

gennyble commented 2 years ago

bytes, they're bytes. we think this is the best solution. now to implementation!

No, I lied, I like explicitly in the header. Assume nothing!