Skip to content

Add comment to generated template package - #132

Merged
kevinushey merged 1 commit into
RcppCore:masterfrom
krlmlr:f-129-doc-flags-template
Sep 17, 2020
Merged

Add comment to generated template package#132
kevinushey merged 1 commit into
RcppCore:masterfrom
krlmlr:f-129-doc-flags-template

Conversation

@krlmlr

@krlmlr krlmlr commented Sep 9, 2020

Copy link
Copy Markdown
Contributor

for completeness.

Add-on to #129.

@kevinushey

Copy link
Copy Markdown
Contributor

I think that, rather than adding this as a comment in src/Makevars, we should either:

  1. Write it to the NAMESPACE directly,
  2. Write a comment out to the user (via message()) saying "Please add importFrom(RcppParallel, ...) to ensure RcppParallel is loaded when your package is used."

@krlmlr

krlmlr commented Sep 10, 2020

Copy link
Copy Markdown
Contributor Author

This comment would have spared ~2 hours of research if it had been there.

The directive is already written to NAMESPACE. It is lost the first time the user calls devtools::document(). It's much more difficult to lose that comment from Makevars, this file isn't touched by automated tools AFAICT.

@kevinushey
kevinushey merged commit be7ea23 into RcppCore:master Sep 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants