fix classname for jsonconfig::config::iterator::key

The current code works but I think it is not intended.
This patch also improves portability with compilers other than g++.