Simplify test case. This test case also applies to PR 6013.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93444 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/Analysis/casts.c b/test/Analysis/casts.c
index 3337b4d..ef398bb 100644
--- a/test/Analysis/casts.c
+++ b/test/Analysis/casts.c
@@ -59,13 +59,9 @@
}
}
-// PR 6035 - Test that a cast of a pointer to long and then to int does not crash SValuator.
-struct pr6035 {
- void *data;
-};
-
-void pr6035_test (struct pr6035 *f) {
- int x;
- x = (long) f->data;
- (void) x;
+// PR 6013 and 6035 - Test that a cast of a pointer to long and then to int does not crash SValuator.
+void pr6013_6035_test(void *p) {
+ unsigned int foo;
+ foo = ((long)(p));
+ (void) foo;
}