Skip to content

Commit

Permalink
untag token upon removal from the precious list
Browse files Browse the repository at this point in the history
  • Loading branch information
Enchufa2 committed Mar 13, 2022
1 parent 136ec60 commit 7ec783f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/barrier.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// barrier.cpp: Rcpp R/C++ interface class library -- write barrier
//
// Copyright (C) 2010 - 2020 Dirk Eddelbuettel and Romain Francois
// Copyright (C) 2021 Dirk Eddelbuettel, Romain Francois and Iñaki Ucar
// Copyright (C) 2021 - 2022 Dirk Eddelbuettel, Romain Francois and Iñaki Ucar
//
// This file is part of Rcpp.
//
Expand Down Expand Up @@ -119,6 +119,7 @@ void Rcpp_precious_remove(SEXP token) {
if (token == R_NilValue || TYPEOF(token) != LISTSXP) {
return;
}
SET_TAG(token, R_NilValue);
SEXP before = CAR(token);
SEXP after = CDR(token);
SETCDR(before, after);
Expand Down

0 comments on commit 7ec783f

Please sign in to comment.