Skip to content

Commit eed5c29

Browse files
author
luke
committed
Reduce false positives from funciton pointer declarations in getFunsHdr.
git-svn-id: https://svn.r-project.org/R/trunk@89091 00db46b3-68df-0310-9c12-caf00c1e9a41
1 parent 9e361e9 commit eed5c29

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/library/tools/R/apitools.R

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,7 @@ getFunsHdr <- function(fpath, lines) {
118118

119119
## these could be incorporated into the regex
120120
lines <- gsub(r"{\s*(const|extern|long|unsigned)\s*}", "", lines)
121+
lines <- gsub(r"{\(\*\s*\w+\s*\)\s*\(}", "(*)(", lines)
121122
lines <- sub(r"{^\s*(\w*[(])}", "void \\1", lines)
122123
lines <- gsub(r"{\(\s*\*\s*(\w+)\s*\)}", "(\\1)", lines)
123124

0 commit comments

Comments
 (0)