Work around gcc-4.8 bug

Seems that gcc-4.8 has problems with templates that use abstract types.
Whatever. Its almost dead code, the template is used in only one place,
so just expand the template by hand.
Merge pull request #1 from opencog/master

Need to pull the gcc-4.8 bug workaround to my branch