Skip to content

Missing exports of S3 methods #501

@fweber144

Description

@fweber144

Running devtools::document() with roxygen2 version 7.3.1 reports the following:

✖ formula.R:808: S3 method `formula.gamm4` needs @export or @exportS3method tag.
✖ divergence_minimizers.R:1216: S3 method `predict.gamm4` needs @export or @exportS3method tag.
✖ divergence_minimizers.R:1179: S3 method `predict.subfit` needs @export or @exportS3method tag.

(see #498 (comment)). To my knowledge, exporting these S3 methods is not strictly necessary at the moment (R <= 4.4.0), but the roxygen2 warning might indicate that this could change in the future. Already for avoiding these roxygen2 warnings, it would probably be better to export those S3 methods.

At some point in the past (1 or 2 years ago), I already tried to export all S3 methods, including the ones mentioned above. At that time, exporting formula.gamm4() and then avoiding explicit formula.gamm4() calls (i.e., replacing them with formula() calls) somehow led to an error which I could not resolve back then. Hence, it might be better to just export the S3 methods mentioned above and not replace their calls with the corresponding "generic-only" calls (this doesn't mean that replacing their calls with the corresponding "generic-only" calls shouldn't be tried again now).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions