Skip to content

Removed redundant template in '__delete_node()' member function of '__forward_list_base' and '__list_imp' classes. #84323

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

Merged
merged 3 commits into from
May 23, 2024

Conversation

2LoS
Copy link
Contributor

@2LoS 2LoS commented Mar 7, 2024

No description provided.

LoS and others added 2 commits March 7, 2024 14:28
@2LoS 2LoS requested a review from a team as a code owner March 7, 2024 14:02
Copy link

github-actions bot commented Mar 7, 2024

Thank you for submitting a Pull Request (PR) to the LLVM Project!

This PR will be automatically labeled and the relevant teams will be
notified.

If you wish to, you can add reviewers by using the "Reviewers" section on this page.

If this is not working for you, it is probably because you do not have write
permissions for the repository. In which case you can instead tag reviewers by
name in a comment by using @ followed by their GitHub username.

If you have received no comments on your PR for a week, you can request a review
by "ping"ing the PR by adding a comment “Ping”. The common courtesy "ping" rate
is once a week. Please remember that you are asking for valuable time from other developers.

If you have further questions, they may be answered by the LLVM GitHub User Guide.

You can also ask questions in a comment on this PR, on the LLVM Discord or on the forums.

@llvmbot llvmbot added the libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi. label Mar 7, 2024
@llvmbot
Copy link
Member

llvmbot commented Mar 7, 2024

@llvm/pr-subscribers-libcxx

Author: None (2LoS)

Changes

Full diff: https://github.com/llvm/llvm-project/pull/84323.diff

2 Files Affected:

  • (modified) libcxx/include/forward_list (-1)
  • (modified) libcxx/include/list (-1)
diff --git a/libcxx/include/forward_list b/libcxx/include/forward_list
index a62b171a46783b..caf9cbbcff8c20 100644
--- a/libcxx/include/forward_list
+++ b/libcxx/include/forward_list
@@ -555,7 +555,6 @@ protected:
     return __guard.__release_ptr();
   }
 
-  template <class... _Args>
   _LIBCPP_HIDE_FROM_ABI void __delete_node(__node_pointer __node) {
     // For the same reason as above, we use the allocator's destroy() method for the value_type,
     // but not for the node itself.
diff --git a/libcxx/include/list b/libcxx/include/list
index 8f0689268e2a5a..0da2ca24ae7eca 100644
--- a/libcxx/include/list
+++ b/libcxx/include/list
@@ -568,7 +568,6 @@ protected:
     return __guard.__release_ptr();
   }
 
-  template <class... _Args>
   _LIBCPP_HIDE_FROM_ABI void __delete_node(__node_pointer __node) {
     // For the same reason as above, we use the allocator's destroy() method for the value_type,
     // but not for the node itself.

Copy link

github-actions bot commented Mar 7, 2024

⚠️ We detected that you are using a GitHub private e-mail address to contribute to the repo.
Please turn off Keep my email addresses private setting in your account.
See LLVM Discourse for more information.

@@ -555,7 +555,6 @@ protected:
return __guard.__release_ptr();
}

template <class... _Args>
Copy link
Member

Choose a reason for hiding this comment

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

Do you know why this was here in the first place?
Were we trying to get around some type-incompleteness?

Could you please make sure we have sufficient tests for the allocator incompleteness requirements?

Copy link
Contributor

Choose a reason for hiding this comment

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

Looks like this is from #65614, which looks like it's just copy-pasted. Checking test coverage would be good though.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@EricWF, could you help me to land this PR, please?

@2LoS 2LoS changed the title Removed dedundant template in '__delete_node()' member function of '__forward_list_base' and '__list_imp' classes. Removed redundant template in '__delete_node()' member function of '__forward_list_base' and '__list_imp' classes. Apr 13, 2024
Copy link
Contributor

@philnik777 philnik777 left a comment

Choose a reason for hiding this comment

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

LGTM assuming we have (indirect) test coverage for __delete_node.

@2LoS
Copy link
Contributor Author

2LoS commented May 22, 2024

@philnik777, can you land this for me, please?

@philnik777 philnik777 merged commit 7b18571 into llvm:main May 23, 2024
Copy link

@2LoS Congratulations on having your first Pull Request (PR) merged into the LLVM Project!

Your changes will be combined with recent changes from other authors, then tested
by our build bots. If there is a problem with a build, you may receive a report in an email or a comment on this PR.

Please check whether problems have been caused by your change specifically, as
the builds can include changes from many authors. It is not uncommon for your
change to be included in a build that fails due to someone else's changes, or
infrastructure issues.

How to do this, and the rest of the post-merge process, is covered in detail here.

If your change does cause a problem, it may be reverted, or you can revert it yourself.
This is a normal part of LLVM development. You can fix your changes and open a new PR to merge them again.

If you don't get any reports, no action is required from you. Your changes are working as expected, well done!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
libc++ libc++ C++ Standard Library. Not GNU libstdc++. Not libc++abi.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants