r-lib / rlang

Low-level API for programming with R
https://rlang.r-lib.org
Other
500 stars 137 forks source link

Update `compat-` files to new naming scheme #1548

Closed hadley closed 1 year ago

hadley commented 1 year ago

@jennybc doesn’t that file come from withr?

jennybc commented 1 year ago

OK I just did what I thought needed to be done. See what you think.

jennybc commented 1 year ago

The name of the file now matches what it claims its name to be.

hadley commented 1 year ago

Isn't https://github.com/r-lib/withr/blob/main/R/compat-defer.R the source of this content? Do I misunderstand?

lionel- commented 1 year ago

yup it is, defer is an import in rlang from withr.

jennybc commented 1 year ago

I see a file here named import-standalone-defer.R. Note the import- prefix.

I don't think any other standalone file is named that way? Nor is the original file in withr named that way. And inside that file, it claims to come from an original name standalone-defer.R, also without import- prefix.

But I seem to be confused about what's going on here and will revert my commit.

lionel- commented 1 year ago

Source files are prefixed with standalone-, and imported files are prefixed with import-standalone-, this way you can tell by the name if a file is an original or a copycat.