Chapter 18 Expressions

Learning objectives:

  • Understand the idea of the abstract syntax tree (AST).
  • Discuss the data structures that underlie the AST:
    • Constants
    • Symbols
    • Calls
  • Explore the idea behind parsing.
  • Explore some details of R’s grammar.
  • Discuss the use or recursive functions to compute on the language.
  • Work with three other more specialized data structures:
    • Pairlists
    • Missing arguments
    • Expression vectors
library(rlang)
library(lobstr)