highlight::sherlock returns a new function, whereas highlight::lestrade returns data(?).
This behavour is inconsistent (and also means the sherlock example in README.md is incorrect):
# Works
highlight::highlight(file = "test.R", detective = highlight::lestrade)
# Doesn't work
highlight::highlight(file = "test.R", detective = highlight::sherlock)
#> Error in UseMethod("filter_") :
#> no applicable method for 'filter_' applied to an object of class "function"
# Works
highlight::highlight(file = "test.R", detective = highlight::sherlock())
highlight::sherlockreturns a new function, whereashighlight::lestradereturns data(?).This behavour is inconsistent (and also means the
sherlockexample in README.md is incorrect):