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

Allow one join suffix to be the empty string #2445

merged 1 commit into from Feb 20, 2017


Copy link

@krlmlr krlmlr commented Feb 19, 2017

Avoids endless loop.

Fixes #2228.

@hadley: PTAL.

// we suffix by .x if this column is in y_columns (and if the suffix is not empty)
if (suffix_x.length() > 0) {
while (
(std::find(y_columns.begin(), y_columns.end(), col_name.get_sexp()) != y_columns.end()) ||
Copy link

@hadley hadley Feb 20, 2017

This seems a bit complicated as a while condition

Copy link
Member Author

@krlmlr krlmlr Feb 20, 2017

Yes. There is also duplication with the R function unique_names(), ideally we'd have one C++ routine for creating column names. Can we merge as-is and postpone cleanup?

Copy link

@hadley hadley Feb 20, 2017

Sounds good

@krlmlr krlmlr requested a review from hadley Feb 20, 2017
@krlmlr krlmlr merged commit 08ebec7 into tidyverse:master Feb 20, 2017
4 checks passed
@krlmlr krlmlr deleted the b-#2228-empty-join branch Feb 20, 2017
Copy link

@lock lock bot commented Jan 18, 2019

This old issue has been automatically locked. If you believe you have found a related problem, please file a new issue (with reprex) and link to this issue.

@lock lock bot locked and limited conversation to collaborators Jan 18, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
None yet
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants