[all-commits] [llvm/llvm-project] 76032b: Check for the overloadable attribute in all the ap...
Aaron Ballman via All-commits
all-commits at lists.llvm.org
Mon Feb 14 05:54:41 PST 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 76032b0e3f58d4abe8d00ac61ff1b2044e076ba7
https://github.com/llvm/llvm-project/commit/76032b0e3f58d4abe8d00ac61ff1b2044e076ba7
Author: Aaron Ballman <aaron at aaronballman.com>
Date: 2022-02-14 (Mon, 14 Feb 2022)
Changed paths:
M clang/docs/ReleaseNotes.rst
M clang/lib/Sema/SemaType.cpp
M clang/test/Sema/overloadable.c
Log Message:
-----------
Check for the overloadable attribute in all the appropriate syntactic locations
When forming the function type from a declarator, we look for an
overloadable attribute before issuing a diagnostic in C about a
function signature containing only .... When the attribute is present,
we allow such a declaration for compatibility with the overloading
rules in C++. However, we were not looking for the attribute in all of
the places it is legal to write it on a declarator and so we only
accepted the signature in some forms and incorrectly rejected the
signature in others.
We now check for the attribute preceding the declarator instead of only
being applied to the declarator directly.
More information about the All-commits
mailing list