Learn R Programming

dynprog (version 0.1.1)

parse_recursion: Parser for the recursion part of a specification.

Description

Parse the recursion part of an expressions.

Usage

parse_recursion(recursion)

Arguments

recursion

The quosure wrapping the recursion of the specification.

Value

A parsed specification for recursions.

Details

The parser return a list with the following components:

  • recursion_env: The environment in which expressions should be evaluated.

  • patterns: A list of patterns, one per recursion case.

  • conditions: A list of conditions, one per recursion case.

  • recursions: A list of expressions, one per recursion case.