Commit Graph

18 Commits

Author SHA1 Message Date
Heejin Ahn d94bacbcf8 [WebAssembly] Handle exception specifications
Summary:
Wasm currently does not fully handle exception specifications. Rather
than crashing,
- This treats `throw()` in the same way as `noexcept`.
- This ignores and prints a warning for `throw(type, ..)`, for a
  temporary measure. This warning is controlled by
  `-Wwasm-exception-spec`, which is on by default. You can suppress the
  warning by using `-Wno-wasm-exception-spec`.

Reviewers: dschuff

Subscribers: sbc100, jgravelle-google, sunfish, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D80061
2020-05-19 01:16:09 -07:00
Richard Sandiford 69ab8b46b8 [Sema][SVE] Fix handling of initialisers for built-in SVE types
The built-in SVE types are supposed to be treated as opaque types.
This means that for initialisation purposes they should be treated
as a single unit, much like a scalar type.

However, as Eli pointed out, actually using "scalar" in the diagnostics
is likely to cause confusion, given the types are logically vectors.
The patch therefore uses custom diagnostics or generalises existing
ones.  Some of the messages use the word "indivisible" to try to make
it clear(er) that these types can't be initialised elementwise.

I don't think it's possible to trigger warn_braces_around_(scalar_)init
for sizeless types as things stand, since the types can't be used as
members or elements of more complex types.  But it seemed better to be
consistent with ext_many_braces_around_(scalar_)init, so the patch
changes it anyway.

Differential Revision: https://reviews.llvm.org/D76689
2020-05-06 12:24:27 +01:00
Richard Sandiford e959931092 [Sema] Put existing warning under -Wexcess-initializers
I have a follow-on patch that uses an alternative wording for
ext_excess_initializers in some cases.  This patch puts it and
a couple of related warnings under their own -W option in order
to avoid a regression in Misc/warning-flags.c.

Differential Revision: https://reviews.llvm.org/D79244
2020-05-06 11:28:40 +01:00
Richard Sandiford fb4574df52 [docs] Regenerate DiagnosticsReference.rst
It looks like it has been a while since the checked-in version of
DiagnosticsReference.rst was regenerated.  I realise there probably
isn't any expectation that the checked-in version is kept up-to-date,
but now that the project is on github and the rst can be viewed directly
from the repo's web interface, it seemed worth having something a bit
more recent.

Differential Revision: https://reviews.llvm.org/D79236
2020-05-06 10:26:47 +01:00
Nick Desaulniers 54c04301b7 fixup: sphinx warning
Fixes the sphinx warning:
tools/clang/docs/DiagnosticsReference.rst:7889: WARNING: Title underline
too short.

That I just introduced in r350877.

llvm-svn: 350878
2019-01-10 19:26:35 +00:00
Nick Desaulniers 2383aad540 [SemaCXX] add -Woverride-init alias to -Winitializer-overrides
Summary:
https://bugs.llvm.org/show_bug.cgi?id=40251
https://github.com/ClangBuiltLinux/linux/issues/307

Reviewers: rsmith

Reviewed By: rsmith

Subscribers: cfe-commits, nathanchance, srhines

Differential Revision: https://reviews.llvm.org/D56522

llvm-svn: 350877
2019-01-10 19:12:39 +00:00
Matt Davis 0090753ef0 [Diagnostic] Fix a warning typo. NFC.
s/aligment/alignment/

llvm-svn: 342068
2018-09-12 18:27:21 +00:00
Duncan P. N. Exon Smith c4f5f605fd Fix malformed table introduced by r330174
http://lab.llvm.org:8011/builders/clang-sphinx-docs/builds/23573

llvm-svn: 330177
2018-04-17 05:48:36 +00:00
Duncan P. N. Exon Smith 2bdf2565a0 Remove GC-related warning terminology
ObjC-GC isn't used any more; clean up this warning text.

rdar://problem/39049693

llvm-svn: 330174
2018-04-17 04:25:18 +00:00
Richard Smith 6631036893 [www] Regenerate diagnostics reference.
llvm-svn: 316701
2017-10-26 21:06:52 +00:00
Richard Smith 9a016602e9 [docs] Regenerate diagnostics reference.
llvm-svn: 300271
2017-04-13 22:44:22 +00:00
Richard Smith cf9f422ba1 [docs] Regenerate DiagnosticsReference.rst. We don't have automatic generation of this set up server-side yet.
llvm-svn: 292637
2017-01-20 19:27:09 +00:00
Richard Smith 14568ff2ad [docs] Fix formatting of   characters so that tables line up properly. Add
padding around table cells so the borders of adjacent tables don't run into
each other (now that they're perfectly aligned).

llvm-svn: 281436
2016-09-14 02:24:50 +00:00
Richard Smith 8cba29181b [docs] Order diagnostic cross-references alphabetically rather than based on
order in the .td file.

llvm-svn: 281434
2016-09-14 01:55:42 +00:00
Richard Smith ce9d586fdb Update DiagnosticsReference and fix emitter to emit -Wpedantic diagnostics and groups in a deterministic order.
llvm-svn: 281433
2016-09-14 01:51:10 +00:00
Richard Smith 9d5f86b694 Color warnings purple rather than orange, to match actual Clang output.
llvm-svn: 281427
2016-09-14 00:35:56 +00:00
Richard Smith ac20531203 Diagnostics reference: "error:" should be red, not orange.
llvm-svn: 281241
2016-09-12 17:55:49 +00:00
Richard Smith b6a3b4ba61 Add a mode to clang-tblgen to generate reference documentation for warning and
remark flags. For now I'm checking in a copy of the built documentation, but we
can replace this with a placeholder (as we do for the attributes reference
documentation) once we enable building this server-side.

llvm-svn: 281192
2016-09-12 05:58:29 +00:00