[inferbo] Add FN test of using global constant

Summary: After a redeclaration of a global constant, it is not parsed as ICE(integral constant expression), which results in FN.

Reviewed By: ezgicicek

Differential Revision: D14299288

fbshipit-source-id: 394afd595
master
Sungkeun Cho 6 years ago committed by Facebook Github Bot
parent b55996d01a
commit 4a013f5bf6

@ -291,6 +291,18 @@ void use_global_Bad() {
a[S::x] = 0;
}
const unsigned int S::x;
void use_global_2_Good() {
int a[50];
a[S::x] = 0;
}
void use_global_2_Bad_FN() {
int a[30];
a[S::x] = 0;
}
class my_class6 {
int* x;

Loading…
Cancel
Save