File: Exceptions_nocall.cpp

package info (click to toggle)
rcpp 1.1.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 7,480 kB
  • sloc: cpp: 27,436; ansic: 7,778; sh: 53; makefile: 2
file content (13 lines) | stat: -rw-r--r-- 268 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
#define RCPP_DEFAULT_INCLUDE_CALL false
#include <Rcpp.h>
using namespace Rcpp;

// [[Rcpp::export]]
void Rcpp_exception(){
    throw Rcpp::exception("ouch");
}

// [[Rcpp::export]]
void eval_error_no_call(){
    Rcpp_eval(Rf_lang1(Rf_install("ouch")), R_EmptyEnv);
}