Why Const Sucks
As could easily be guessed by the title, this article discusses the issues I have with const - primarily with an eye towards D but also with regards to C++. My view of const has changed considerably over the years, and this talks about that. In fact, the situation with const is part of what led me to D. I originally come from a C++ background. It's what I used on my own before programming in school and what I originally used in high school and college. I read books like Effective C++ and C++ Gotchas about good and bad practices (I've always been a bit surprised that many programmers don't think that the correct thing to do when learning a language is to read a bunch of books about it to learn it through and through), and one of the things that I definitely bought into was const-correctness - that is, the idea that any function that is "logically" const should be marked as const and that as much as possible should be const. As such, when I later ended up using Java for school and work,
Why Const Sucks Jonathan M Davis: The Long-Winded D Guy Home Articles Talks Projects About rss Why Const Sucks As could easily be guessed by the title, this article discusses the issues I have with const - primarily with an eye towards D but also with regards to C++. My view of const has changed considerably over the years, and this talks about that. In fact, the situation with const is part of what led me to D. A Bit of Background I originally come from a C++ background. It's what I used on my own before programming in school and what I originally used in high school and college. I read books
Explore this link on the map →related reading
- A fucking rant about fucking const vs fucking let - @jamiebuildsjamie.build
- Immutable object - Wikipediaen.wikipedia.org
- Variables and Mutability - The Rust Programming Languagedoc.rust-lang.org
- Moves - Rust: A Better C++ Than C++thecodedmessage.com
- References and Borrowing - The Rust Programming Languagedoc.rust-lang.org
- Google C++ Style Guidegoogle.github.io
- A half-hour to learn Rustfasterthanli.me
- Learn C++ – Skill up with our free tutorialslearncpp.com
- What is Ownership? - The Rust Programming Languagedoc.rust-lang.org
- Destroy All Values: Designing Deinitialization in Programming Languages - Faultloregankra.github.io
- Reading 8: Mutability & Immutabilityweb.mit.edu
- Rust Language Cheat Sheetcheats.rs