[PATCH] D129048: Rewording the "static_assert" to static assertion

Aaron Ballman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Jul 13 10:04:59 PDT 2022


aaron.ballman added inline comments.


================
Comment at: clang/lib/Parse/ParseDeclCXX.cpp:929
 
+  // saving the token used for static assertion.
+  Token SavedTok = Tok;
----------------



================
Comment at: clang/lib/Parse/ParseDeclCXX.cpp:995
   DeclEnd = Tok.getLocation();
-  ExpectAndConsumeSemi(diag::err_expected_semi_after_static_assert);
+  ExpectAndConsumeSemi(diag::err_expected_semi_after_static_assert , SavedTok.getName()); //passing the token used to the error message.
 
----------------
My suggestion is slightly different from Erich's (mine has whitespace and capitalization fixes), also, this is definitely over the 80 col limit, so you should format the patch.


================
Comment at: clang/test/CXX/expr/expr.prim/expr.prim.req/nested-requirement.cpp:48
 }
\ No newline at end of file

----------------
xgupta wrote:
> a 'newline' is missing here.
Still missing the newline at the end of the file here.


================
Comment at: clang/test/CXX/temp/temp.constr/temp.constr.constr/partial-specializations.cpp:85
 }
\ No newline at end of file

----------------
xgupta wrote:
> same
Same here


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D129048



More information about the cfe-commits mailing list