Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Take list name from property name #379

Merged
merged 7 commits into from
Nov 29, 2023
Merged

Take list name from property name #379

merged 7 commits into from
Nov 29, 2023

Conversation

hadley
Copy link
Member

@hadley hadley commented Nov 22, 2023

Fixes #371

@hadley hadley requested a review from DavisVaughan November 22, 2023 21:13
R/property.R Outdated Show resolved Hide resolved
R/property.R Outdated Show resolved Hide resolved
R/property.R Outdated

if (is_property(x)) {
x$name <- name
if (is.null(x$name)) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So an existing property $name has priority over the name supplied in the list() call if you supply both, right? I can't tell if that seems right or not, but don't have strong feelings either way

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmmm, I think the list name should win.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That was also my gut feeling

@hadley hadley merged commit 42536b6 into main Nov 29, 2023
12 checks passed
@hadley hadley deleted the prop-name branch November 29, 2023 22:47
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.

Don't require two property names
2 participants