llvm-project/clang/lib/Basic
Aaron Ballman 2cb2cd242c Change the behavior of implicit int diagnostics
C89 allowed a type specifier to be elided with the resulting type being
int, aka implicit int behavior. This feature was subsequently removed
in C99 without a deprecation period, so implementations continued to
support the feature. Now, as with implicit function declarations, is a
good time to reevaluate the need for this support.

This patch allows -Wimplicit-int to issue warnings in C89 mode (off by
default), defaults the warning to an error in C99 through C17, and
disables support for the feature entirely in C2x. It also removes a
warning about missing declaration specifiers that really was just an
implicit int warning in disguise and other minor related cleanups.
2022-05-04 08:35:47 -04:00
..
Targets [PowerPC] Enable CR bits support for Power8 and above. 2022-05-02 12:06:15 -05:00
Attributes.cpp [OpenMP] Support OpenMP 5.1 attributes 2021-07-12 06:51:19 -04:00
Builtins.cpp Treat `std::move`, `forward`, etc. as builtins. 2022-04-20 17:58:31 -07:00
CLWarnings.cpp Reland "[clang-cl] Accept `#pragma warning(disable : N)` for some N" 2021-09-30 15:03:23 -04:00
CMakeLists.txt [Clang][CSKY] Add the CSKY target and compiler driver 2022-04-06 11:37:37 +08:00
CharInfo.cpp
CodeGenOptions.cpp [NFC] Remove duplicate isNoBuiltinFunc method 2021-03-10 09:18:55 +01:00
Cuda.cpp [AMDGPU][clang] Definition of gfx11 subtarget 2022-04-29 13:55:56 -04:00
DarwinSDKInfo.cpp [Clang] Extract availability mapping from VersionMap for watchOS/tvOS 2022-01-05 17:00:03 -08:00
Diagnostic.cpp [NFC] Prevent shadowing a variable declared in `if` 2022-04-28 22:22:27 -04:00
DiagnosticIDs.cpp Reland [clangd] More precisely enable clang warnings through ClangTidy options 2022-04-30 11:07:11 +02:00
DiagnosticOptions.cpp
ExpressionTraits.cpp
FileEntry.cpp Basic: Add native support for stdin to SourceManager and FileManager 2020-12-23 15:18:50 -08:00
FileManager.cpp [VFS] RedirectingFileSystem only replace path if not already mapped 2022-04-11 14:52:48 -07:00
FileSystemStatCache.cpp
IdentifierTable.cpp [CodeCompletion][clangd] Clean __uglified parameter names in completion & hover 2022-01-26 15:51:17 +01:00
LangOptions.cpp Change the behavior of implicit int diagnostics 2022-05-04 08:35:47 -04:00
LangStandards.cpp [clang] NFC, move CompilerInvocation::setLangDefaults to LangOptions.h 2022-04-13 09:44:39 +02:00
Module.cpp [clang][modules] Report module maps affecting `no_undeclared_includes` modules 2022-03-07 10:47:46 +01:00
NoSanitizeList.cpp [clang][patch] Inclusive language, modify filename SanitizerBlacklist.h to NoSanitizeList.h 2021-02-22 15:11:37 -05:00
ObjCRuntime.cpp
OpenCLOptions.cpp [OpenCL] Turn global vector into static array. NFCI. 2022-03-05 19:16:28 +01:00
OpenMPKinds.cpp [clang][OpenMP5.1] Initial parsing/sema for has_device_addr 2022-04-08 21:19:38 -07:00
OperatorPrecedence.cpp
ProfileList.cpp [clang] Replace report_fatal_error(std::string) uses with report_fatal_error(Twine) 2021-10-06 11:43:19 +01:00
SanitizerSpecialCaseList.cpp
Sanitizers.cpp [clang-cl][sanitizer] Add -fsanitize-address-use-after-return to clang. 2021-06-11 12:07:35 -07:00
SourceLocation.cpp [NFC][clang] Return underlying strings directly instead of OS.str() 2021-12-09 16:05:46 -08:00
SourceManager.cpp [Basic] SourceManager docs: macro expansion SLocs aren't a single token. NFC 2022-04-25 19:57:47 +02:00
Stack.cpp
TargetID.cpp [Basic] Drop unnecessary const from return types (NFC) 2021-12-29 08:55:37 -08:00
TargetInfo.cpp [Clang] Fix the guaranteed alignment of memory returned by malloc/new on OpenBSD 2022-04-22 02:03:55 -04:00
Targets.cpp [Clang][CSKY] Add the CSKY target and compiler driver 2022-04-06 11:37:37 +08:00
Targets.h
TokenKinds.cpp [Pseudo] Token/TokenStream, PP directive parser. 2022-02-23 17:52:02 +01:00
TypeTraits.cpp
Version.cpp [NFC][clang] Return underlying strings directly instead of OS.str() 2021-12-09 16:05:46 -08:00
Warnings.cpp [Sema] Special case -Werror-implicit-function-declaration and reject other -Werror- 2020-11-05 10:25:30 -08:00
XRayInstr.cpp [clang][cli] Generate and round-trip CodeGen options 2021-02-09 11:43:38 +01:00
XRayLists.cpp