Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Calls to Rf_error

Open
#4 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
45/100
Issue type
Refactor
Clarity
Mostly clear
Activity status
Stale
Tech stack
cpp, r
Domain
backend

Research direction

Search the repository's C++ sources for calls to Rf_error and review each use in the context of RcppCore/Rcpp/issues/1247. Replace ordinary uses with Rcpp::stop or parenthesize justified callback uses, then verify that no unreviewed Rf_error calls remain.

Written by the indexing model from the issue text.

Description

We've detected calls to Rf_error in your C++ code, which may be problematic, see RcppCore/Rcpp/issues/1247. Rcpp will warn about these calls in the near future, and will error later on. The purpose is to force package developers to think about their uses of Rf_error to:

  • substitute them with Rcpp::stop in most cases, which does proper unwinding, calling destructors in the process to avoid memory leaks; or
  • protect them with parenthesis as in (Rf_error)(...) if these uses are justified (e.g. in callbacks that are passed on to R functions).

Please review your Rf_error calls and adjust them accordingly.

Dominant language
R
Stars
17
Forks
1
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Similar issues

More R issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.