repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
ubsan: -Wreturn-type and ubsan trap-on-error
[official-gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
ubsan
/
return-8.C
blob
354c96098d282f9e7e366ba5cd8fb8c1f11ad8df
1
// { dg-additional-options "-fsanitize=undefined -fsanitize-undefined-trap-on-error" }
2
3
bool b;
4
5
int f() {
6
if (b) return 42;
7
} // { dg-warning "-Wreturn-type" }
8
9
int main() { f(); }