foo.cpp: In function 'int main()':
foo.cpp:42:9: warning: 'auto' changes meaning in C++11; please remove it [-Wc++0x-compat]
for(auto t : x){
^
foo.cpp:42:14: error: 't' does not name a type
for(auto t : x){
^
foo.cpp:46:1: error: expected ';' before '}' token
}
^
foo.cpp:46:1: error: expected primary-expression before '}' token
foo.cpp:46:1: error: expected ';' before '}' token
foo.cpp:46:1: error: expected primary-expression before '}' token
foo.cpp:46:1: error: expected ')' before '}' token
foo.cpp:46:1: error: expected primary-expression before '}' token
foo.cpp:46:1: error: expected ';' before '}' token