From: Christopher Dykes Date: Wed, 10 Aug 2016 20:18:10 +0000 (-0700) Subject: Mark FormatArg::error as noreturn X-Git-Tag: v2016.08.15.00~21 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=b62a976d20c5c5b186a9888a34e8557ee59f046d;p=folly.git Mark FormatArg::error as noreturn Summary: Because, if no inlining is enabled, the absence of this attribute caused compile errors due to functions that were expected to return a value not returning a value. Reviewed By: meyering Differential Revision: D3698413 fbshipit-source-id: 8f3505b17a2fa7b9710e3fb56d18c6ca00feacb3 --- diff --git a/folly/FormatArg.h b/folly/FormatArg.h index 6f25299e..701654b3 100644 --- a/folly/FormatArg.h +++ b/folly/FormatArg.h @@ -211,7 +211,7 @@ inline std::string FormatArg::errorStr(Args&&... args) const { } template -inline void FormatArg::error(Args&&... args) const { +[[noreturn]] inline void FormatArg::error(Args&&... args) const { throw BadFormatArg(errorStr(std::forward(args)...)); }