Bug 16376 - tools::codoc in src/library/tools/R/QC.R uses the wrong regular expression function
Summary: tools::codoc in src/library/tools/R/QC.R uses the wrong regular expression fu...
Status: UNCONFIRMED
Alias: None
Product: R
Classification: Unclassified
Component: Add-ons (show other bugs)
Version: R 3.2.0
Hardware: All All
: P5 major
Assignee: R-core
URL:
Depends on:
Blocks:
 
Reported: 2015-05-10 13:07 UTC by Yixuan Qiu
Modified: 2015-05-10 13:07 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Yixuan Qiu 2015-05-10 13:07:57 UTC
Lines 665~667 of src/library/tools/R/QC.R have the following code:

ind <- grep(.S4_method_markup_regexp, functions)
if(any(ind))
    functions <- functions[!ind]

The use of "any()" and "!ind" indicates that "ind" should be a logical vector. Hence grep() should be replaced by grepl().