mirror of
https://github.com/github/codeql.git
synced 2025-12-17 17:23:36 +01:00
34 lines
494 B
C
34 lines
494 B
C
|
|
void f1(void) {
|
|
int x;
|
|
long y;
|
|
long long z;
|
|
x = 3;
|
|
y = x; // Compiler generated cast
|
|
z = x; // Compiler generated cast
|
|
// Compiler generated return
|
|
}
|
|
|
|
void f2(void) {
|
|
int x;
|
|
x = 3;
|
|
return;
|
|
}
|
|
|
|
void f3(void) {
|
|
int x;
|
|
x = 3;
|
|
return;
|
|
x = 4;
|
|
// No compiler generated return here, as this is unreachable
|
|
}
|
|
|
|
void f4(void) {
|
|
int x;
|
|
while (1) {
|
|
x = 3;
|
|
}
|
|
// No compiler generated return here, as this is unreachable
|
|
}
|
|
|