summaryrefslogtreecommitdiffstats
path: root/test/Analysis/coverage.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/Analysis/coverage.c')
-rw-r--r--test/Analysis/coverage.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/Analysis/coverage.c b/test/Analysis/coverage.c
index 73d78da..8116913 100644
--- a/test/Analysis/coverage.c
+++ b/test/Analysis/coverage.c
@@ -92,3 +92,11 @@ void coverage9(int *x) {
function_which_gives_up_settonull(&x);
y = (*x); // no warning
}
+
+static void empty_function(){
+}
+int use_empty_function(int x) {
+ x = 0;
+ empty_function();
+ return 5/x; //expected-warning {{Division by zero}}
+}
OpenPOWER on IntegriCloud