|
|
|
|
|
by tialaramex
374 days ago
|
|
But you were critiquing Rust's model, yet you've written C++ here. I agree it's perfectly easy to write the bug in C++. In Rust this improved type doesn't have the defect, to call Rust's analogue of your setDate function you must have the exclusive mutable reference, which means there's no concurrency problem. You have to do a whole lot of extra work to write the bug and why would you, just write what you meant and it behaves correctly. |
|
Give it another go at understanding what I'm saying, cheers!