Files
clang-p2996/clang/lib/Sema/SemaCast.cpp
Kristina Bessonova 2fbd1323e7 [Sema] Make C++ functional-style cast warn about dropped qualifiers (-Wcast-qual)
Functional-style cast (i.e. a simple-type-specifier or typename-specifier
followed by a parenthesize single expression [expr.type.conv]) is equivalent
to the C-style cast, so that makes sense they have identical behavior
including warnings.

This also matches GCC https://godbolt.org/z/b8Ma9Thjb.

Reviewed By: rnk, aaron.ballman

Differential Revision: https://reviews.llvm.org/D159133
2023-09-05 12:48:38 +02:00

130 KiB