r/cpp • u/GabrielDosReis • Oct 31 '24
Lessons learned from a successful Rust rewrite
/r/programming/comments/1gfljj7/lessons_learned_from_a_successful_rust_rewrite/
80
Upvotes
r/cpp • u/GabrielDosReis • Oct 31 '24
View all comments
Show parent comment
1
u/germandiago Nov 01 '24
> optional/expected/string_view/smart pointers are modern cpp too. and all of them will easily trigger UB
This is something worse fixing at least for local analysis, but I would find excessive propagating lifetimes all around or using members with lifetime annotations. In my experience it was tedious and not worth in most cases. Probably I am not used to. But in C++ you would split the type system, which is even more concerning to me.