Sign in
gnu
/
gcc
/
93ac832f1846e4867aa6537f76f510fab8e3e87d
/
.
/
gcc
/
testsuite
/
g++.dg
/
ubsan
/
return-2.C
blob: 068210d884c5d5608d26bb88eae931a70f0ef63a [
file
] [
log
] [
blame
]
// { dg-do run }
// { dg-options "-fsanitize=return -fno-sanitize-recover=return -Wno-return-type" }
struct
S
{
S
();
~
S
();
};
S
::
S
()
{}
S
::~
S
()
{}
int
foo
(
int
x
)
{
S a
;
{
S b
;
if
(
x
)
return
1
;
}
}
int
main
()
{
foo
(
1
);
foo
(
14
);
}