func_from_expr: Get funcion(s) from a single expression. Usually a single...

Description Usage Arguments Details Value

View source: R/parse-exprs.R

Description

Get funcion(s) from a single expression. Usually a single function, but not necessarily.

Usage

1
func_from_expr(expr, rfile, env)

Arguments

expr

Expression to evaluate.

rfile

Name of the R file being parsed, to be able to use it in a warning message.

env

Environment to store the parsed objects in.

Details

If the expression has a function token and at least one assignment, then we assume that it is a function definition and evaluate it to get the function name. This is the current algorithm:

Value

A named list of length one. (It is easy to concatenate these lists in the caller, hence the format. A list with a name and an expression is less convenient.)


MangoTheCat/functionMap documentation built on May 7, 2019, 2:10 p.m.