Skip to content

[analyzer] Fix broken testcase #75216

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
Dec 12, 2023
Merged

[analyzer] Fix broken testcase #75216

merged 1 commit into from
Dec 12, 2023

Conversation

NagyDonat
Copy link
Contributor

When merging commit c873f77 I didn't manually rebase it onto the tip of the main branch, so I didn't notice that the testcase that's added by it needs to be tweaked to account for the effects of commit 2f29ded (which was also merged by me a few days ago).

When merging commit c873f77 I didn't
manually rebase it onto the tip of the main branch, so I didn't notice
that the testcase that's added by it needs to be tweaked to account for
the effects of commit 2f29ded (which
was also merged by me a few days ago).
@NagyDonat NagyDonat requested a review from nico December 12, 2023 17:09
@llvmbot llvmbot added the clang Clang issues not falling into any other category label Dec 12, 2023
@llvmbot
Copy link
Member

llvmbot commented Dec 12, 2023

@llvm/pr-subscribers-clang

Author: None (DonatNagyE)

Changes

When merging commit c873f77 I didn't manually rebase it onto the tip of the main branch, so I didn't notice that the testcase that's added by it needs to be tweaked to account for the effects of commit 2f29ded (which was also merged by me a few days ago).


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

1 Files Affected:

  • (modified) clang/test/Analysis/enum-cast-out-of-range.cpp (+1-1)
diff --git a/clang/test/Analysis/enum-cast-out-of-range.cpp b/clang/test/Analysis/enum-cast-out-of-range.cpp
index 82086b7305787..a5ac4f3fd0567 100644
--- a/clang/test/Analysis/enum-cast-out-of-range.cpp
+++ b/clang/test/Analysis/enum-cast-out-of-range.cpp
@@ -226,7 +226,7 @@ enum WidgetKind { A=1, B, C, X=99 }; // expected-note {{enum declared here}}
 void foo() {
   WidgetKind c = static_cast<WidgetKind>(3);  // OK
   WidgetKind x = static_cast<WidgetKind>(99); // OK
-  WidgetKind d = static_cast<WidgetKind>(4);  // expected-warning {{The value provided to the cast expression is not in the valid range of values for 'WidgetKind'}}
+  WidgetKind d = static_cast<WidgetKind>(4);  // expected-warning {{The value '4' provided to the cast expression is not in the valid range of values for 'WidgetKind'}}
 
   ignore_unused(c, x, d);
 }

@nico nico merged commit 4b7d400 into llvm:main Dec 12, 2023
@nico
Copy link
Contributor

nico commented Dec 12, 2023

This made bots happy again. Thanks for the quick fix!

@NagyDonat NagyDonat deleted the enumcast_quickfix branch April 16, 2024 15:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clang Clang issues not falling into any other category
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants