Used typedef instead of more advanced C++11 "using x = y;" syntax to make code compile on gcc 4.6.