This is an archive of the discontinued LLVM Phabricator instance.

Use "default member initializer" instead of "in-class initializer" for diagnostics
ClosedPublic

Authored by aaron.ballman on Sep 28 2020, 1:43 PM.

Details

Reviewers
rsmith
Summary

This changes some diagnostics to use terminology from the standard rather than invented terminology, which improves consistency with other diagnostics as well. There are no functional changes intended other than wording and naming.

Diff Detail

Event Timeline

aaron.ballman requested review of this revision.Sep 28 2020, 1:43 PM
aaron.ballman created this revision.

Thanks!

clang/include/clang/Basic/DiagnosticParseKinds.td
864–868

Consider "initialization of" -> "initializer for", so we use the standard term in full.

clang/include/clang/Basic/DiagnosticSemaKinds.td
8506–8525

For a static member, it's just an initializer, not a default member initializer. I think "in-class initializer" is probably the best we can say here.

8534–8535

Likewise, this case is an initializer for a static member, and is not a default member initializer.

Updating based on review feedback.

aaron.ballman marked 3 inline comments as done.Sep 29 2020, 5:57 AM

Missed a test case.

rsmith accepted this revision.Sep 29 2020, 11:10 AM

Thanks!

This revision is now accepted and ready to land.Sep 29 2020, 11:10 AM

Thank you for the review! I've commit in 15fbae8ac303d8601ea95418d4818cb50d0765e1