[libcxx-commits] [libcxx] [libc++][NFC] Use early returns in basic_string::operator= (PR #137145)
via libcxx-commits
libcxx-commits at lists.llvm.org
Thu Apr 24 02:27:50 PDT 2025
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff HEAD~1 HEAD --extensions -- libcxx/include/string
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/libcxx/include/string b/libcxx/include/string
index 8e8186a53..ce36b4952 100644
--- a/libcxx/include/string
+++ b/libcxx/include/string
@@ -2880,7 +2880,7 @@ basic_string<_CharT, _Traits, _Allocator>::operator=(const basic_string& __str)
__annotate_delete();
auto __guard = std::__make_scope_guard(__annotate_new_size(*this));
- __rep_ = __str.__rep_;
+ __rep_ = __str.__rep_;
return *this;
}
``````````
</details>
https://github.com/llvm/llvm-project/pull/137145
More information about the libcxx-commits
mailing list