Skip to content

Commit

Permalink
Bump the trunk major version to 14
Browse files Browse the repository at this point in the history
and clear the release notes.
  • Loading branch information
tstellar committed Jul 28, 2021
1 parent 88e66fa commit 08c766a
Show file tree
Hide file tree
Showing 22 changed files with 66 additions and 410 deletions.
95 changes: 5 additions & 90 deletions clang-tools-extra/docs/ReleaseNotes.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
====================================================
Extra Clang Tools 13.0.0 (In-Progress) Release Notes
Extra Clang Tools 14.0.0 (In-Progress) Release Notes
====================================================

.. contents::
Expand All @@ -10,15 +10,15 @@ Written by the `LLVM Team <https://llvm.org/>`_

.. warning::

These are in-progress notes for the upcoming Extra Clang Tools 13 release.
These are in-progress notes for the upcoming Extra Clang Tools 14 release.
Release notes for previous releases can be found on
`the Download Page <https://releases.llvm.org/download.html>`_.

Introduction
============

This document contains the release notes for the Extra Clang Tools, part of the
Clang release 13.0.0. Here we describe the status of the Extra Clang Tools in
Clang release 14.0.0. Here we describe the status of the Extra Clang Tools in
some detail, including major improvements from the previous release and new
feature work. All LLVM releases may be downloaded from the `LLVM releases web
site <https://llvm.org/releases/>`_.
Expand All @@ -32,7 +32,7 @@ main Clang web page, this document applies to the *next* release, not
the current one. To see the release notes for a specific release, please
see the `releases page <https://llvm.org/releases/>`_.

What's New in Extra Clang Tools 13.0.0?
What's New in Extra Clang Tools 14.0.0?
=======================================

Some of the major new features and improvements to Extra Clang Tools are listed
Expand Down Expand Up @@ -67,105 +67,20 @@ The improvements are...
Improvements to clang-tidy
--------------------------

- The `run-clang-tidy.py` helper script is now installed in `bin/` as
`run-clang-tidy`. It was previously installed in `share/clang/`.

- Added command line option `--fix-notes` to apply fixes found in notes
attached to warnings. These are typically cases where we are less confident
the fix will have the desired effect.

- libToolingCore and Clang-Tidy was refactored and now checks can produce
highlights (`^~~~~` under fragments of the source code) in diagnostics.
Existing and new checks in the future can be expected to start implementing
this functionality.
This change only affects the visual rendering of diagnostics, and does not
alter the behavior of generated fixes.
The improvements are...

New checks
^^^^^^^^^^

- New :doc:`bugprone-implicit-widening-of-multiplication-result
<clang-tidy/checks/bugprone-implicit-widening-of-multiplication-result>` check.

Diagnoses instances of an implicit widening of multiplication result.

- New :doc:`concurrency-thread-canceltype-asynchronous
<clang-tidy/checks/concurrency-thread-canceltype-asynchronous>` check.

Finds ``pthread_setcanceltype`` function calls where a thread's cancellation
type is set to asynchronous.

- New :doc:`altera-id-dependent-backward-branch
<clang-tidy/checks/altera-id-dependent-backward-branch>` check.

Finds ID-dependent variables and fields that are used within loops. This
causes branches to occur inside the loops, and thus leads to performance
degradation.

- New :doc:`altera-unroll-loops
<clang-tidy/checks/altera-unroll-loops>` check.

Finds inner loops that have not been unrolled, as well as fully unrolled
loops with unknown loops bounds or a large number of iterations.

- New :doc:`bugprone-easily-swappable-parameters
<clang-tidy/checks/bugprone-easily-swappable-parameters>` check.

Finds function definitions where parameters of convertible types follow each
other directly, making call sites prone to calling the function with
swapped (or badly ordered) arguments.

- New :doc:`cppcoreguidelines-prefer-member-initializer
<clang-tidy/checks/cppcoreguidelines-prefer-member-initializer>` check.

Finds member initializations in the constructor body which can be placed into
the initialization list instead.

- New :doc:`bugprone-unhandled-exception-at-new
<clang-tidy/checks/bugprone-unhandled-exception-at-new>` check.

Finds calls to ``new`` with missing exception handler for ``std::bad_alloc``.

- New `readability-suspicious-call-argument
<clang-tidy/checks/readability-suspicious-call-argument>`_ check

Finds function calls where the arguments passed are provided out of order,
based on the difference between the argument name and the parameter names
of the function.

New check aliases
^^^^^^^^^^^^^^^^^

- New alias :doc:`cert-pos47-c
<clang-tidy/checks/cert-pos47-c>` to
:doc:`concurrency-thread-canceltype-asynchronous
<clang-tidy/checks/concurrency-thread-canceltype-asynchronous>` was added.


Changes in existing checks
^^^^^^^^^^^^^^^^^^^^^^^^^^

- Improved :doc:`bugprone-signal-handler
<clang-tidy/checks/bugprone-signal-handler>` check.

Added an option to choose the set of allowed functions.

- Improved :doc:`readability-uniqueptr-delete-release
<clang-tidy/checks/readability-uniqueptr-delete-release>` check.

Added an option to choose whether to refactor by calling the ``reset`` member
function or assignment to ``nullptr``.
Added support for pointers to ``std::unique_ptr``.

Removed checks
^^^^^^^^^^^^^^

- The readability-deleted-default check has been removed.

The clang warning `Wdefaulted-function-deleted
<https://clang.llvm.org/docs/DiagnosticsReference.html#wdefaulted-function-deleted>`_
will diagnose the same issues and is enabled by default.

Improvements to include-fixer
-----------------------------

Expand Down
4 changes: 2 additions & 2 deletions clang-tools-extra/docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@
# built documents.
#
# The short version.
version = '13'
version = '14'
# The full version, including alpha/beta/rc tags.
release = '13'
release = '14'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
149 changes: 10 additions & 139 deletions clang/docs/ReleaseNotes.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
========================================
Clang 13.0.0 (In-Progress) Release Notes
Clang 14.0.0 (In-Progress) Release Notes
========================================

.. contents::
Expand All @@ -10,15 +10,15 @@ Written by the `LLVM Team <https://llvm.org/>`_

.. warning::

These are in-progress notes for the upcoming Clang 13 release.
These are in-progress notes for the upcoming Clang 14 release.
Release notes for previous releases can be found on
`the Download Page <https://releases.llvm.org/download.html>`_.

Introduction
============

This document contains the release notes for the Clang C/C++/Objective-C
frontend, part of the LLVM Compiler Infrastructure, release 13.0.0. Here we
frontend, part of the LLVM Compiler Infrastructure, release 14.0.0. Here we
describe the status of Clang in some detail, including major
improvements from the previous release and new feature work. For the
general LLVM release notes, see `the LLVM
Expand All @@ -35,7 +35,7 @@ main Clang web page, this document applies to the *next* release, not
the current one. To see the release notes for a specific release, please
see the `releases page <https://llvm.org/releases/>`_.

What's New in Clang 13.0.0?
What's New in Clang 14.0.0?
===========================

Some of the major new features and improvements to Clang are listed
Expand All @@ -46,13 +46,7 @@ sections with improvements to Clang's support for those languages.
Major New Features
------------------

- Guaranteed tail calls are now supported with statement attributes
``[[clang::musttail]]`` in C++ and ``__attribute__((musttail))`` in C. The
attribute is applied to a return statement (not a function declaration),
and an error is emitted if a tail call cannot be guaranteed, for example if
the function signatures of caller and callee are not compatible. Guaranteed
tail calls enable a class of algorithms that would otherwise use an
arbitrary amount of stack space.
- ...

Improvements to Clang's diagnostics
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Expand All @@ -62,22 +56,12 @@ Improvements to Clang's diagnostics
Non-comprehensive list of changes in this release
-------------------------------------------------

- The default value of _MSC_VER was raised from 1911 to 1914. MSVC 19.14 has the
support to overaligned objects on x86_32 which is required for some LLVM
passes.
- ...

New Compiler Flags
------------------

- ``-Wreserved-identifier`` emits warning when user code uses reserved
identifiers.

- ``-fstack-usage`` generates an extra .su file per input source file. The .su
file contains frame size information for each function defined in the source
file.

- ``-Wnull-pointer-subtraction`` emits warning when user code may have
undefined behaviour due to subtraction involving a null pointer.
- ...

Deprecated Compiler Flags
-------------------------
Expand All @@ -87,25 +71,12 @@ Deprecated Compiler Flags
Modified Compiler Flags
-----------------------

- -Wshadow now also checks for shadowed structured bindings
- ``-B <prefix>`` (when ``<prefix>`` is a directory) was overloaded to additionally
detect GCC installations under ``<prefix>`` (``lib{,32,64}/gcc{,-cross}/$triple``).
This behavior was incompatible with GCC, caused interop issues with
``--gcc-toolchain``, and was thus dropped. Specify ``--gcc-toolchain=<dir>``
instead. ``-B``'s other GCC-compatible semantics are preserved:
``$prefix/$triple-$file`` and ``$prefix$file`` are searched for executables,
libraries, includes, and data files used by the compiler.
- ``-Wextra`` now also implies ``-Wnull-pointer-subtraction.``
- ...

Removed Compiler Flags
-------------------------

- The clang-cl ``/fallback`` flag, which made clang-cl invoke Microsoft Visual
C++ on files it couldn't compile itself, has been removed.

- ``-Wreturn-std-move-in-c++11``, which checked whether an entity is affected by
`CWG1579 <https://wg21.link/CWG1579>`_ to become implicitly movable, has been
removed.
- ...

New Pragmas in Clang
--------------------
Expand All @@ -117,9 +88,6 @@ Attribute Changes in Clang

- ...

- Added support for C++11-style ``[[]]`` attributes on using-declarations, as a
clang extension.

Windows Support
---------------

Expand All @@ -131,9 +99,6 @@ C Language Changes in Clang
C++ Language Changes in Clang
-----------------------------

- The oldest supported GNU libstdc++ is now 4.8.3 (released 2014-05-22).
Clang workarounds for bugs in earlier versions have been removed.

- ...

C++20 Feature Support
Expand Down Expand Up @@ -173,22 +138,11 @@ X86 Support in Clang
Internal API Changes
--------------------

These are major API changes that have happened since the 12.0.0 release of
Clang. If upgrading an external codebase that uses Clang as a library,
this section should help get you past the largest hurdles of upgrading.

- ...

Build System Changes
--------------------

These are major changes to the build system that have happened since the 12.0.0
release of Clang. Users of the build system should adjust accordingly.

- The option ``LIBCLANG_INCLUDE_CLANG_TOOLS_EXTRA`` no longer exists. There were
two releases with that flag forced off, and no uses were added that forced it
on. The recommended replacement is clangd.

- ...

AST Matchers
Expand All @@ -199,90 +153,7 @@ AST Matchers
clang-format
------------

- Option ``SpacesInLineCommentPrefix`` has been added to control the
number of spaces in a line comments prefix.

- Option ``SortIncludes`` has been updated from a ``bool`` to an
``enum`` with backwards compatibility. In addition to the previous
``true``/``false`` states (now ``CaseSensitive``/``Never``), a third
state has been added (``CaseInsensitive``) which causes an alphabetical sort
with case used as a tie-breaker.

.. code-block:: c++

// Never (previously false)
#include "B/A.h"
#include "A/B.h"
#include "a/b.h"
#include "A/b.h"
#include "B/a.h"

// CaseSensitive (previously true)
#include "A/B.h"
#include "A/b.h"
#include "B/A.h"
#include "B/a.h"
#include "a/b.h"

// CaseInsensitive
#include "A/B.h"
#include "A/b.h"
#include "a/b.h"
#include "B/A.h"
#include "B/a.h"

- ``BasedOnStyle: InheritParentConfig`` allows to use the ``.clang-format`` of
the parent directories to overwrite only parts of it.

- Option ``IndentAccessModifiers`` has been added to be able to give access
modifiers their own indentation level inside records.

- Option ``PPIndentWidth`` has been added to be able to configure pre-processor
indentation independent from regular code.

- Option ``ShortNamespaceLines`` has been added to give better control
over ``FixNamespaceComments`` when determining a namespace length.

- Support for Whitesmiths has been improved, with fixes for ``namespace`` blocks
and ``case`` blocks and labels.

- Option ``EmptyLineAfterAccessModifier`` has been added to remove, force or keep
new lines after access modifiers.

- Checks for newlines in option ``EmptyLineBeforeAccessModifier`` are now based
on the formatted new lines and not on the new lines in the file. (Fixes
https://llvm.org/PR41870.)

- Option ``SpacesInAngles`` has been improved, it now accepts ``Leave`` value
that allows to keep spaces where they are already present.

- Option ``AllowShortIfStatementsOnASingleLine`` has been improved, it now
accepts ``AllIfsAndElse`` value that allows to put "else if" and "else" short
statements on a single line. (Fixes https://llvm.org/PR50019.)

- Option ``BreakInheritanceList`` gets a new style, ``AfterComma``. It breaks
only after the commas that separate the base-specifiers.

- Option ``LambdaBodyIndentation`` has been added to control how the body of a
lambda is indented. The default ``Signature`` value indents the body one level
relative to whatever indentation the signature has. ``OuterScope`` lets you
change that so that the lambda body is indented one level relative to the scope
containing the lambda, regardless of where the lambda signature was placed.

- Option ``IfMacros`` has been added. This lets you define macros that get
formatted like conditionals much like ``ForEachMacros`` get styled like
foreach loops.

- ``git-clang-format`` no longer formats changes to symbolic links. (Fixes
https://llvm.org/PR46992.)

- Makes ``PointerAligment: Right`` working with ``AlignConsecutiveDeclarations``.
(Fixes https://llvm.org/PR27353)

- Option ``AlignArrayOfStructure`` has been added to allow for ordering array-like
initializers.

- Support for formatting JSON file (\*.json) has been added to clang-format.
- ...

libclang
--------
Expand Down
Loading

0 comments on commit 08c766a

Please sign in to comment.