These are used to extract and format source references. As they are not part of the public rlang API they are reimplemented here.
src_loc(srcref, dir = getwd())relish(x, dir = getwd())
Character vector containing either a source location (for src_loc()) or a path (for
relish()).
A srcref object
Directory path
File path
src_loc(): Return source location from a srcref. If no srcref is found, return
"".
relish(): Tidy file paths by removing instances of dir from x. Ensures that
we get a relative path for x.