File tree Expand file tree Collapse file tree 3 files changed +14
-11
lines changed
include/Rcpp/exceptions/cpp11 Expand file tree Collapse file tree 3 files changed +14
-11
lines changed Original file line number Diff line number Diff line change 112017-04-17 James J Balamuta <
[email protected] >
22
3- * inst/include/Rcpp/exceptions.h: modified exceptions macros to support
3+ * inst/include/Rcpp/Rcpp/exceptions/cpp11/exceptions.h: Removed
4+ semicolons from RCPP_ADVANCED_EXCEPTION_CLASS to quiet 'extra ;' -Wpedantic
5+
6+ * inst/include/Rcpp/exceptions.h: Modified exceptions macros to support
47 a default string and removed generated stop, warning from file.
58 * inst/include/Rcpp/Rcpp/exceptions/cpp98/exceptions.h: Contains
69 generated RCPP_ADVANCED_EXCEPTION_CLASS macro, stop & warning.
Original file line number Diff line number Diff line change 1515 (James Balamuta in \ghpr {674 } addressing \ghit {673 }).
1616 \item Added \code {printf }- like syntax support for exception classes and
1717 variadic templating for \code {Rcpp :: stop } and \code {Rcpp :: warning }
18- (James Balamuta in \ghpr {675 }).
18+ (James Balamuta in \ghpr {676 }).
1919 \item Exception messages have been rewritten to provide additional
20- information. (James Balamuta in \ghpr {675 }, ?? addressing \ghit {184 }).
20+ information. (James Balamuta in \ghpr {676 }, ?? addressing \ghit {184 }).
2121 }
2222 \item Changes in Rcpp Documentation :
2323 \itemize {
Original file line number Diff line number Diff line change 2828namespace Rcpp {
2929
3030#define RCPP_ADVANCED_EXCEPTION_CLASS (__CLASS__, __WHAT__ ) \
31- class __CLASS__ : public std ::exception{ \
31+ class __CLASS__ : public std ::exception { \
3232 public: \
33- __CLASS__ ( ) throw () : message( std::string(__WHAT__) + " ." ){} ; \
33+ __CLASS__ ( ) throw () : message( std::string(__WHAT__) + " ." ){} \
3434 __CLASS__ ( const std::string& message ) throw () : \
35- message ( std::string(__WHAT__) + " : " + message + " ." ){} ; \
35+ message ( std::string(__WHAT__) + " : " + message + " ." ){} \
3636 template <typename ... Args> \
3737 __CLASS__ ( const char * fmt, Args&&... args ) throw () : \
38- message ( tfm::format(fmt, std::forward<Args>(args)...) ){} ; \
39- virtual ~__CLASS__ () throw (){} ; \
40- virtual const char * what () const throw() { return message.c_str () ; } \
38+ message ( tfm::format(fmt, std::forward<Args>(args)... ) ){} \
39+ virtual ~__CLASS__ () throw (){} \
40+ virtual const char * what () const throw() { return message.c_str (); } \
4141 private: \
42- std::string message ; \
43- } ;
42+ std::string message; \
43+ };
4444
4545template <typename ... Args>
4646inline void warning (const char * fmt, Args&&... args ) {
You can’t perform that action at this time.
0 commit comments