c++ style
better type handling/casts
drop suncc support from singleton class
cast to int