MCPcopy Create free account
hub / github.com/RcppCore/Rcpp / runit_pl_insert

Function runit_pl_insert

inst/tinytest/cpp/language.cpp:172–188  ·  view source on GitHub ↗

[[Rcpp::export]]

Source from the content-addressed store, hash-verified

170
171// [[Rcpp::export]]
172Pairlist runit_pl_insert(){
173 Pairlist p ;
174 p.push_back( 1 ) ;
175 p.push_back( 10.0 ) ;
176 p.push_back( 20.0 ) ;
177
178 /* insert in 2nd position */
179 p.insert( 1, Named( "bla", "bla" ) ) ;
180
181 /* insert in front */
182 p.insert( 0, 30.0 ) ;
183
184 /* insert in back */
185 p.insert( 5, "foobar" ) ;
186
187 return p ;
188}
189
190// [[Rcpp::export]]
191Pairlist runit_pl_replace(){

Callers

nothing calls this directly

Calls 3

NamedFunction · 0.85
push_backMethod · 0.45
insertMethod · 0.45

Tested by

no test coverage detected