[PATCH] D56992: [clang] Mark lambda-to-function-pointer conversion as noexcept
Ignat Loskutov via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Jan 21 05:14:20 PST 2019
loskutov updated this revision to Diff 182779.
loskutov added a comment.
Fixed the comment.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D56992/new/
https://reviews.llvm.org/D56992
Files:
clang/lib/Sema/SemaLambda.cpp
Index: clang/lib/Sema/SemaLambda.cpp
===================================================================
--- clang/lib/Sema/SemaLambda.cpp
+++ clang/lib/Sema/SemaLambda.cpp
@@ -1227,9 +1227,7 @@
FunctionProtoType::ExtProtoInfo ConvExtInfo(
S.Context.getDefaultCallingConvention(
/*IsVariadic=*/false, /*IsCXXMethod=*/true));
- // The conversion function is always const.
- // C++17 also obliges it to be noexcept (which it in fact is),
- // and previous standards don't forbid that either.
+ // The conversion function is always const and noexcept.
ConvExtInfo.TypeQuals = Qualifiers();
ConvExtInfo.TypeQuals.addConst();
ConvExtInfo.ExceptionSpec.Type = EST_BasicNoexcept;
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D56992.182779.patch
Type: text/x-patch
Size: 703 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190121/65f39092/attachment.bin>
More information about the cfe-commits
mailing list