Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int i = 0;
- int a[4];
- a[i] = i++; //<--- UB here
- int i = 0;
- int foo(){
- return i++;
- }
- int main(){
- int a[4];
- a[i] = foo();
- return 0;
- }
- a[i] = foo();
- a[i] = i++;
- a[i] = foo();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement