refactor variable_info.cpp

this is a strict refactor which shouldn't change the compiled code.
get rid of preprocessor conditional

having 2 different implementations (one for c++11 and one for c++03)
makes the code harder to maintain.