[PATCH] D123955: [C2x] Disallow functions without prototypes/functions with identifier lists

Aaron Ballman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 19 08:20:07 PDT 2022


aaron.ballman updated this revision to Diff 423629.
aaron.ballman marked an inline comment as not done.
aaron.ballman added a comment.

Updated based on review feedback.

- Added `-fstrict-prototypes` command line option (but there is NO `-fno-strict-prototypes` support)
- Changed the way the language option works to be a little less fragile
- Fixed the static analyzer to create a function with a prototype instead


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D123955/new/

https://reviews.llvm.org/D123955

Files:
  clang/docs/ReleaseNotes.rst
  clang/include/clang/Basic/LangOptions.def
  clang/include/clang/Basic/LangOptions.h
  clang/include/clang/Driver/Options.td
  clang/lib/AST/ASTContext.cpp
  clang/lib/Parse/ParseDecl.cpp
  clang/lib/Sema/SemaDecl.cpp
  clang/lib/Sema/SemaType.cpp
  clang/lib/StaticAnalyzer/Core/MemRegion.cpp
  clang/test/Driver/strict-prototypes.c
  clang/test/Frontend/strict-prototypes.c
  clang/test/Parser/c2x-attributes.c
  clang/test/Parser/c2x-func-prototype.c
  clang/test/Sema/attr-c2x.c
  clang/test/Sema/c2x-func-prototype.c
  clang/www/c_status.html

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D123955.423629.patch
Type: text/x-patch
Size: 15620 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220419/7b186c3a/attachment-0001.bin>


More information about the cfe-commits mailing list