warn_map_keys: Warn about unmatched keys in an argument map

View source: R/channel_args.R

warn_map_keysR Documentation

Warn about unmatched keys in an argument map

Description

Shared by resolve_channel_args() and resolve_interval_args(): unrecognised keys are warned about and ignored; omitted keys (only reported by callers when the map has no unnamed fallback) fall back to the argument's default.

Usage

warn_map_keys(
  arg_nm,
  unknown,
  omitted,
  what,
  match_hint,
  env = rlang::caller_env()
)

Arguments

arg_nm

Character; the argument name.

unknown, omitted

Character vectors (or NULL) of unrecognised and unspecified keys.

what

Character; the key kind, "channel" or "interval".

match_hint

Character; what valid keys must match, may contain cli markup.

env

The calling environment or a defused call, used to report errors and warnings as coming from the user-facing function rather than the validator.

Value

invisible(NULL), invoked for its warning side effects.


mnirs documentation built on Sept. 13, 2026, 1:06 a.m.