|
Boost Users : |
From: dizzy (dizzy_at_[hidden])
Date: 2008-01-23 08:11:15
On Wednesday 23 January 2008 15:01:46 Russell L. Carter wrote:
> Hi,
> This is probably a novice template question. I am curious what
> I am doing wrong here, where I'm trying to get a function object
> holding a base member of a CRTP class. gcc 4.2.3 complains about:
>
> type/value mismatch at argument 1 in template parameter list for
> 'template<class Derived> template<template<template<class> class MHBase>
> template<class Derived> template<class> class MHBase> struct MHBase<
> <template-parameter-1-1> >::fooFO
I dont understand what you want to achieve so I can't recommend something
based on that but strictly speaking about the issue, fooFO receives a
template template parameter and not a type so you cannot give it an
instantiation of MHBase, you probably want to give it MHBase. So:
FooFunc ff = fooFO<MHBase>(*this);
(even tho I don't understand why in that case fooFO is made to receive a
template template parameter being defined inside MHBase, you do not need the
flexibility of being able to give it something else than MHBase do you?)
-- Mihai RUSU Email: dizzy_at_[hidden] "Linux is obsolete" -- AST
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net