C++ is not a superset of C.
That warning is still accurate, but it is less useful when stated without a language mode. The 2019 version of this post surveyed C constructs that do not work in C++. The 2026 update does not retire that advice. It makes the border more precise.
The question is no longer only “does valid C compile as C++?” Often it is: C17, C23, C++17, C++20, or C++23?
Designated initialization is the clean example. C++20 added designated initializers, but not the whole C feature. C designators can target array elements, nested members, and fields out of declaration order. The C++20 form is narrower: direct non-static data members, declaration order, and all-designated clauses. C-style array designators, nested designators, out-of-order designators, and mixed positional/designated clauses remain outside the portable C++ form.
The old empty-parameter-list trap moved too. In C17 and earlier, void f() did not mean the same thing C++ programmers normally expect. It did not provide a prototype saying “no parameters.” C23 changed that: void f() now behaves as though declared with void. So the compatibility answer depends on which C mode is in play.
The malloc row is still easy to misread. In C++, void* does not implicitly convert to an object pointer type. But the cast is not the interesting part. Lifetime is. C++20 repaired some implicit-lifetime cases around allocation, but allocation still does not call constructors, initialize values, or make non-implicit-lifetime types safe to use without construction.
Other checkpoint rows remain: discarding const, enum behavior including C23 changes, restrict, and flexible array members. Each row is less a trivia question than a reminder that source compatibility, ABI boundaries, object lifetime, and compiler mode are different obligations.
The practical rule is simple: when discussing C/C++ compatibility, label the language mode before drawing the conclusion. “Valid C” and “valid C++” are not precise enough anymore.
Read the full essay on lospino.so: C Constructs That Still Don’t Work in C++ - and a Few That Changed
Original essay published on lospino.so on 2026-05-20. This Substack dispatch is an adapted pointer to the canonical version, not a mirrored copy.

