This patch should fix the build failures following 7e01924 when building
with GCC. These failures were mostly caused by GCC's poor support of C++
templates (namely, partial template specialization).
To work around that problem, this patch makes use of overloading and get
rid of the templated structs and specialized structs.
Signed-off-by: Med Ismail Bennani <medismail.bennani@gmail.com>