"Competitive Advantage with D" is one of the keynotes at C++Now 2017

Guillaume Piolat via Digitalmars-d-announce digitalmars-d-announce at puremagic.com
Sun Apr 23 05:04:08 PDT 2017


On Sunday, 23 April 2017 at 10:16:14 UTC, Walter Bright wrote:
> On 4/11/2017 8:10 AM, Guillaume Piolat wrote:
>> Newer C++ almost erased leaks and memory errors if you follow 
>> it.
>
> C and C++ don't have memory leaks if you are careful. The 
> trouble is, there's no checking.

The rules of leak-free, exception-safe C++11 aren't so hard.
- single-owneship for everything, invent fake owner if needed
- std::unique_ptr for owning pointer, raw pointers for borrowed
   (unique_ptr neatly avoids to write a RAII wrapper for 
everything)

When teams internalize these rules, no more leaks, no more 
double-free, etc.
Hence Rust that sanctified this style.


More information about the Digitalmars-d-announce mailing list