Skip to content

[libc][stdlib] Move LIBC_INLINE after template and before constexpr #95037

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 1 commit into from
Jun 10, 2024

Conversation

PiJoules
Copy link
Contributor

No description provided.

@llvmbot
Copy link
Member

llvmbot commented Jun 10, 2024

@llvm/pr-subscribers-libc

Author: None (PiJoules)

Changes

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

1 Files Affected:

  • (modified) libc/src/stdlib/block.h (+2-2)
diff --git a/libc/src/stdlib/block.h b/libc/src/stdlib/block.h
index ce26add082d0a..afb18c1ef738f 100644
--- a/libc/src/stdlib/block.h
+++ b/libc/src/stdlib/block.h
@@ -39,8 +39,8 @@ LIBC_INLINE constexpr size_t align_down(size_t value, size_t alignment) {
 }
 
 /// Returns the value rounded down to the nearest multiple of alignment.
-LIBC_INLINE template <typename T>
-constexpr T *align_down(T *value, size_t alignment) {
+template <typename T>
+LIBC_INLINE constexpr T *align_down(T *value, size_t alignment) {
   return reinterpret_cast<T *>(
       align_down(reinterpret_cast<size_t>(value), alignment));
 }

@PiJoules PiJoules merged commit fd4a740 into llvm:main Jun 10, 2024
6 of 7 checks passed
@PiJoules PiJoules deleted the move-LIBC_INLINE branch June 10, 2024 22:01
Lukacma pushed a commit to Lukacma/llvm-project that referenced this pull request Jun 12, 2024
@HerrCai0907 HerrCai0907 mentioned this pull request Jun 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants