Rcpp Version 0.12.12
macros.h File Reference
Include dependency graph for macros.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define RCPP_DECORATE(__FUN__)   __FUN__##__rcpp__wrapper__
 
#define RCPP_GET_NAMES(x)   Rf_getAttrib(x, R_NamesSymbol)
 
#define RCPP_GET_CLASS(x)   Rf_getAttrib(x, R_ClassSymbol)
 
#define BEGIN_RCPP
 
#define VOID_END_RCPP
 
#define END_RCPP   VOID_END_RCPP return R_NilValue;
 
#define END_RCPP_RETURN_ERROR
 
#define Rcpp_error(MESSAGE)   throw Rcpp::exception(MESSAGE, __FILE__, __LINE__)
 

Macro Definition Documentation

#define END_RCPP_RETURN_ERROR
Value:
} \
} \
catch (std::exception &__ex__) { \
return exception_to_try_error(__ex__); \
} \
catch (...) { \
return string_to_try_error("c++ exception (unknown reason)"); \
} \
return R_NilValue;
SEXP interruptedError()
Definition: Interrupt.h:40
SEXP exception_to_try_error(const std::exception &ex)
Definition: exceptions.h:310
SEXP string_to_try_error(const std::string &str)
Definition: exceptions.h:290

Definition at line 71 of file macros.h.

#define RCPP_DECORATE (   __FUN__)    __FUN__##__rcpp__wrapper__

Definition at line 25 of file macros.h.

#define Rcpp_error (   MESSAGE)    throw Rcpp::exception(MESSAGE, __FILE__, __LINE__)

Definition at line 85 of file macros.h.

#define RCPP_GET_CLASS (   x)    Rf_getAttrib(x, R_ClassSymbol)

Definition at line 27 of file macros.h.

#define VOID_END_RCPP
Value:
} \
rcpp_output_type = 1 ; \
} \
catch(Rcpp::exception& __ex__) { \
rcpp_output_type = 2 ; \
rcpp_output_condition = PROTECT(rcpp_exception_to_r_condition(__ex__)) ; \
} \
catch( std::exception& __ex__ ){ \
rcpp_output_type = 2 ; \
rcpp_output_condition = PROTECT(exception_to_r_condition(__ex__)) ; \
} \
catch( ... ){ \
rcpp_output_type = 2 ; \
rcpp_output_condition = PROTECT(string_to_try_error("c++ exception (unknown reason)")) ; \
} \
if( rcpp_output_type == 1 ){ \
Rf_onintr() ; \
} \
if( rcpp_output_type == 2 ){ \
SEXP stop_sym = Rf_install( "stop" ) ; \
SEXP expr = PROTECT( Rf_lang2( stop_sym , rcpp_output_condition ) ) ; \
Rf_eval( expr, R_GlobalEnv ) ; \
}
SEXP exception_to_r_condition(const std::exception &ex)
Definition: exceptions.h:278
SEXP rcpp_exception_to_r_condition(const Rcpp::exception &ex)
Definition: exceptions.h:260
SEXP string_to_try_error(const std::string &str)
Definition: exceptions.h:290

Definition at line 39 of file macros.h.

Referenced by class_< Class >::setProperty().