fixed typename template bug found by gcc