StefanSalewski / rust-chess

Port of salewski-chess from Nim to Rust
MIT License
2 stars 1 forks source link

Stupid error in fn much_faster_write_to_bit_buffer() #1

Closed StefanSalewski closed 8 months ago

StefanSalewski commented 8 months ago

Of course it should be

collector[bpos..(bpos + 8)].copy_from_slice(&buf.to_le_bytes()[0..8]);

in both cases. Because buf is 8 byte in size, not 4 :-)

That error lead to errors and sometimes gave crashes, as movelist matched not the board content. We should fix this issue soon.

StefanSalewski commented 8 months ago

Fixed.