Parent Frames and Backwards Compatibility

This post will be short and sweet – I wanted to discuss one of the techniques I used for preserving backwards compatibility with some functions in sparklyr whose signature had changed, using some tricks for accessing + modifying the ‘parent frame’ of a function.

Read More →

Pitfalls in Writing Portable C++98 Code

I’ve now made enough submissions to CRAN that have crashed and burned on Solaris, that I think it’s now time to put some of the pitfalls I’ve bumped into in writing. My goal is for this blog post to be a mini-checklist package authors can run through before submitting a C++-code containing package to CRAN. (If you happen to be a CRAN maintainer who has stumbled upon this blog post, I apologize for all the trouble I’ve caused in my various package submissions. Let this be my recompense.)

Read More →

Top-Down Operator Precedence Parsing with R

Parsers are a topic that have been brewing in the back of my head for a while now. Mainly, “how do I write one?” and “I really want to write one!”. There’s something very … zen, about the idea of writing a program that understands how to read and interpret another program.

Read More →

Introduction to C++ Variadic Templates

This is a friendly introduction to variadic templates (and thereby, variadic functions) in C++. We can use variadic functions to write functions that accept an arbitrary number of arguments.

Read More →

What is a Function?

Let’s investigate what, underneath the covers, an R function really is, and how the components are used when R evaluates a function. In doing so, we’ll take a number of detours, as understanding how R function calls really work requires an understanding of some subtle details. By the end of this, we’ll be able to simulate what R does internally when it evaluates a function.

Read More →