Closed fitzgen closed 4 months ago
I am interested. Thanks for pinging me.
Right, so the actual logic around grow/shrink and alignment had to change a bit, not just the test.
That or alternatively the test could have accepted Err(_)
in the case where requested new alignment was greater than the old alignment, but I figured I'd loosen things up a little while I was here.
Nice. Yes, I guess no reason to refuse to increase alignment, if the address is already aligned.
Can I ask you one random question that has nothing to do with this issue? (just don't want to open an issue/discussion just for 1 simple question)
Is the reason for filling the buffers backwards (start at the back, and move towards the front) to make alignment calculations more efficient?
Is the reason for filling the buffers backwards (start at the back, and move towards the front) to make alignment calculations more efficient?
I wrote a whole blog post about this :)
https://fitzgeraldnick.com/2019/11/01/always-bump-downwards.html
Haha oops! Well I guess that answers my question (in spades). Thank you, will digest.
cc @overlookmotel: just an FYI in case you were interested in how I ended up doing this.