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

[libc] Fix aarch64 build error in FEnvSafeTest change #89826

Merged
merged 1 commit into from
Apr 23, 2024

Conversation

frobtech
Copy link
Contributor

@frobtech frobtech commented Apr 23, 2024

No description provided.

@llvmbot
Copy link
Collaborator

llvmbot commented Apr 23, 2024

@llvm/pr-subscribers-libc

Author: Roland McGrath (frobtech)

Changes

When the characteristics of a procedure depend on a procedure that
hasn't yet been defined, the compiler currently emits an unconditional
error message. This includes the case of a procedure whose
characteristics depend, perhaps indirectly, on itself. However, in the
case where the characteristics of a procedure are needed to resolve a
generic, we should not emit an error for a hitherto undefined procedure
-- either the call will resolve to another specific procedure, in which
case the error is spurious, or it won't, and then an error will issue
anyway.

Fixes #88677.


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

1 Files Affected:

  • (modified) libc/test/UnitTest/FEnvSafeTest.cpp (+1-1)
diff --git a/libc/test/UnitTest/FEnvSafeTest.cpp b/libc/test/UnitTest/FEnvSafeTest.cpp
index 43aebc3f36e7b3..905aa928937387 100644
--- a/libc/test/UnitTest/FEnvSafeTest.cpp
+++ b/libc/test/UnitTest/FEnvSafeTest.cpp
@@ -36,7 +36,7 @@ void FEnvSafeTest::set_fenv(const fenv_t &fenv) {
 void FEnvSafeTest::expect_fenv_eq(const fenv_t &before_fenv,
                                   const fenv_t &after_fenv) {
 #if defined(LIBC_TARGET_ARCH_IS_AARCH64)
-  using LIBC_NAMESPACE::fputil::FEnv::FPState;
+  using FPState = LIBC_NAMESPACE::fputil::FEnv::FPState;
   const FPState &before_state = reinterpret_cast<const FPState &>(before_fenv);
   const FPState &after_state = reinterpret_cast<const FPState &>(after_fenv);
 

@frobtech frobtech changed the title [flang] Make proc characterization error conditional for generics (#89429) [libc] Fix aarch64 build error in FEnvSafeTest change Apr 23, 2024
@frobtech frobtech merged commit 859de94 into llvm:main Apr 23, 2024
5 of 6 checks passed
Copy link
Contributor

@michaelrj-google michaelrj-google left a comment

Choose a reason for hiding this comment

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

Post submit review: LGTM

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.

None yet

3 participants