Stroustrup objects to adding Contracts to C++

H. S. Teoh hsteoh at qfbox.info
Tue Nov 10 19:42:38 UTC 2026


On Tue, Nov 10, 2026 at 11:19:45AM +0000, strawberry9 via Digitalmars-d wrote:
> On Monday, 9 November 2026 at 00:40:29 UTC, Walter Bright wrote:
> > https://www.stroustrup.com/Contracts_fundamental_flaws.pdf
> > 
> > An interesting read, relevant to resurging interest in improving D's
> > contracts.
> 
> also an interesting read:
> 
> https://www9.open-std.org/JTC1/SC22/WG21/docs/papers/2026/p4433r0.pdf
> 
> 22 years later... and it's still going.. what a joke C++ is.

What a mess.  I'm glad I found D so many years ago and no longer have to
deal with the train wreck that is C++.  At work I still have to deal
with C, which, in spite of its flaws, at least have *well-known* flaws
with well-known mitigations.  As opposed to the minefield that is C++,
the spec of which I doubt anyone even fully comprehends, where there are
15 ways of writing the same thing and 16 of them are either wrong,
dangerous, outdated, have serious vulnerabilities, or will just plain
explode in your face. Most of which have no known mitigations, or the
mitigations themselves suffer from a whole slew of similar problems.
And with every new revision they're adding brand new ways of shooting
yourself in the foot, covering up the wound with scotch tape and
potter's clay, and then erasing all the evidence, all in one single
syntactic construct conveniently gift-wrapped for you by your favorite
C++ compiler.

D may have its flaws and dark corners, but compared to C++, it's heaven
on earth. ;-)


T

-- 
Engineering almost by definition should break guidelines. -- Ali Çehreli


More information about the Digitalmars-d mailing list