[PATCH] D128844: Improve the formatting of static_assert messages

Corentin Jabot via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Jun 29 11:44:53 PDT 2022


cor3ntin created this revision.
Herald added a subscriber: wenlei.
Herald added a project: All.
cor3ntin requested review of this revision.
Herald added projects: clang, libc++.
Herald added subscribers: libcxx-commits, cfe-commits.
Herald added a reviewer: libc++.

Display 'static_assert failed: message' instead of
'static_assert failed "message"' to be consistent
with other implementations and be slightly more
readable.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D128844

Files:
  clang/include/clang/Basic/DiagnosticSemaKinds.td
  clang/lib/Sema/SemaDeclCXX.cpp
  clang/test/C/drs/dr0xx.c
  clang/test/CXX/dcl.dcl/p4-0x.cpp
  clang/test/CXX/expr/expr.prim/expr.prim.id/p3.cpp
  clang/test/PCH/cxx-static_assert.cpp
  clang/test/Sema/static-assert.c
  clang/test/SemaCXX/int-ptr-cast-SFINAE.cpp
  clang/test/SemaCXX/static-assert.cpp
  libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_add.verify.cpp
  libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_add_explicit.verify.cpp
  libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_sub.verify.cpp
  libcxx/test/libcxx/atomics/atomics.types.operations/atomics.types.operations.req/atomic_fetch_sub_explicit.verify.cpp
  libcxx/test/libcxx/input.output/file.streams/fstreams/filebuf/traits_mismatch.fail.cpp
  libcxx/test/libcxx/input.output/file.streams/fstreams/traits_mismatch.fail.cpp
  libcxx/test/libcxx/input.output/iostream.format/input.streams/traits_mismatch.fail.cpp
  libcxx/test/libcxx/input.output/iostream.format/output.streams/traits_mismatch.fail.cpp
  libcxx/test/libcxx/input.output/string.streams/traits_mismatch.fail.cpp
  libcxx/test/libcxx/iterators/predef.iterators/reverse.iterators/bad_template_argument.verify.cpp
  libcxx/test/libcxx/utilities/memory/util.smartptr/util.smartptr.shared/function_type_default_deleter.fail.cpp
  libcxx/test/libcxx/utilities/tuple/tuple.tuple/tuple.cnstr/PR20855_tuple_ref_binding_diagnostics.fail.cpp
  libcxx/test/libcxx/utilities/utility/pairs/pairs.pair/pair.tuple_element.fail.cpp
  libcxx/test/libcxx/utilities/variant/variant.variant/variant.helper/variant_alternative.fail.cpp
  libcxx/test/std/algorithms/alg.modifying.operations/alg.random.sample/sample.fail.cpp
  libcxx/test/std/algorithms/alg.sorting/alg.min.max/requires_forward_iterator.fail.cpp
  libcxx/test/std/containers/associative/map/map.cons/deduct.fail.cpp
  libcxx/test/std/containers/associative/multimap/multimap.cons/deduct.fail.cpp
  libcxx/test/std/containers/sequences/array/array.fill/fill.fail.cpp
  libcxx/test/std/containers/sequences/array/array.swap/swap.fail.cpp
  libcxx/test/std/containers/sequences/array/array.tuple/get.fail.cpp
  libcxx/test/std/containers/sequences/array/array.tuple/tuple_element.fail.cpp
  libcxx/test/std/containers/sequences/vector/vector.modifiers/resize_not_move_insertable.fail.cpp
  libcxx/test/std/containers/views/views.span/span.sub/subspan.verify.cpp
  libcxx/test/std/experimental/language.support/support.coroutines/coroutine.handle/coroutine.handle.export/from_address.fail.cpp
  libcxx/test/std/language.support/support.dynamic/ptr.launder/launder.types.fail.cpp
  libcxx/test/std/numerics/numbers/illformed.verify.cpp
  libcxx/test/std/numerics/rand/rand.eng/rand.eng.lcong/params.fail.cpp
  libcxx/test/std/strings/basic.string/char.bad.verify.cpp
  libcxx/test/std/strings/string.view/char.bad.fail.cpp
  libcxx/test/std/time/time.hms/hhmmss.fail.cpp
  libcxx/test/std/utilities/any/any.nonmembers/any.cast/any_cast_request_invalid_value_category.fail.cpp
  libcxx/test/std/utilities/any/any.nonmembers/any.cast/const_correctness.verify.cpp
  libcxx/test/std/utilities/any/any.nonmembers/any.cast/not_copy_constructible.verify.cpp
  libcxx/test/std/utilities/any/any.nonmembers/any.cast/reference_types.fail.cpp
  libcxx/test/std/utilities/intseq/intseq.make/make_integer_seq.fail.cpp
  libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/ctor.fail.cpp
  libcxx/test/std/utilities/optional/optional.object/optional.object.ctor/deduct.fail.cpp
  libcxx/test/std/utilities/optional/optional.object/optional_requires_destructible_object.fail.cpp
  libcxx/test/std/utilities/optional/optional.syn/optional_in_place_t.fail.cpp
  libcxx/test/std/utilities/utility/forward/forward.fail.cpp
  libcxx/test/std/utilities/variant/variant.relops/relops_bool_conv.fail.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D128844.441111.patch
Type: text/x-patch
Size: 69270 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220629/6fd17acf/attachment-0001.bin>


More information about the cfe-commits mailing list