Skip to content

Commit

Permalink
Speed improvement to f_bind_rows.
Browse files Browse the repository at this point in the history
  • Loading branch information
NicChr committed Nov 15, 2024
1 parent 8dcb44f commit e6d1d29
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions R/f_bind.R
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,11 @@ f_bind_rows <- function(..., .fill = TRUE){
collapse::rowbind(..., return = "data.frame", fill = .fill)
}

dots <- lapply(dots, df_ungroup)

if (!cpp_any_frames_exotic(dots)){

# We can use collapse::rowbind if data frames
# contain simple atomic vectors
reconstruct(template, do.call(fast_rowbind, dots))
reconstruct(template, fast_rowbind(dots))
} else {
col_prototypes <- as.list(cheapr::sset(template, 0))

Expand Down

0 comments on commit e6d1d29

Please sign in to comment.