seth@lemmy.world to Programming@programming.dev · edit-28 months agoC++ creator rebuts White House warningwww.infoworld.comexternal-linkmessage-square15fedilinkarrow-up10arrow-down10file-text
arrow-up10arrow-down1external-linkC++ creator rebuts White House warningwww.infoworld.comseth@lemmy.world to Programming@programming.dev · edit-28 months agomessage-square15fedilinkfile-text
minus-squarevext01@lemmy.sdf.orglinkfedilinkarrow-up0·8 months agoI agree for the most part, but writing data structures with shared mutable state can be a total pain in Rust.
minus-squareFal@yiffit.netlinkfedilinkEnglisharrow-up0arrow-down1·8 months agoHow so? That’s like, the thing that makes rust awesome to write.
minus-squarevext01@lemmy.sdf.orglinkfedilinkarrow-up0·8 months agoIt’s hard to get those kinds of data structures through the borrow checker. Try writing a doubly linked list.
minus-squareFal@yiffit.netlinkfedilinkEnglisharrow-up0arrow-down1·8 months agoIt’s because it’s hard to make them correct. It’s not any harder to write it in rust than in C. Just C lets you do it wrong
I agree for the most part, but writing data structures with shared mutable state can be a total pain in Rust.
How so? That’s like, the thing that makes rust awesome to write.
It’s hard to get those kinds of data structures through the borrow checker.
Try writing a doubly linked list.
It’s because it’s hard to make them correct. It’s not any harder to write it in rust than in C. Just C lets you do it wrong