Skip to content
This repository was archived by the owner on Jul 30, 2019. It is now read-only.
This repository was archived by the owner on Jul 30, 2019. It is now read-only.

styles.assignment.notinfcall and functions like system.time, within, local #10

@flodel

Description

@flodel

This may be related to halpo's issue #5.

system.time, within, local are some of R's function where using assignments inside the arguments are perfectly ok, e.g:

GOOD

system.time(a <- sleep(1))

BAD

system.time(a = sleep(1))

GOOD

within(cars, speed.dist <- speed * dist)

BAD

within(cars, speed.dist = speed * dist)

Would it be possible to modify styles.assignment.notinfcall to handle such exceptions? If not, I would consider removing styles.assignment.notinfcall from lint's default list of tests: lint.style.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions