serialize: Document integer width assumptions we are making when calculating compact sizes#14475
serialize: Document integer width assumptions we are making when calculating compact sizes#14475practicalswift wants to merge 1 commit intobitcoin:masterfrom
Conversation
745b01f to
82cea43
Compare
…ulating compact sizes
82cea43 to
4486f2a
Compare
|
utACK 25ae1a1 |
25ae1a1 to
4486f2a
Compare
|
@hebasto Updated. Please re-review :-) |
|
Let's assume a platform with |
|
@hebasto As I read the code more adjustments would be needed to the serialisation code to make it work properly under such a platform. I don't think changing FWIW I think the platform requirements are reasonable. My goal with this PR is just making the platform requirements explicit and immediately obvious to compilers, humans and static analysers :-) I think a compile time check is the most elegant and non-intrusive way to achieve that goal. |
Agree. ACK 4486f2a |
Document floating-point width assumptions we are making in the serialization codeRationale: