HomePhabricator

[c++20] P1143R2: Add support for the C++20 'constinit' keyword.

Description

[c++20] P1143R2: Add support for the C++20 'constinit' keyword.

This is mostly the same as the
[[clang::require_constant_initialization]] attribute, but has a couple
of additional syntactic and semantic restrictions.

In passing, I added a warning for the attribute form being added after
we have already seen the initialization of the variable (but before we
see the definition); that case previously slipped between the cracks and
the attribute was silently ignored.

Details

Committed
rsmithWed, Sep 4, 1:30 PM
Parents
rL370971: [NewPM][Sancov] Make Sancov a Module Pass instead of 2 Passes
Branches
Unknown
Tags
Unknown