I'm designing an interface, by which users can define a class that tells what they want to do.  

The code is something like the following,

```
#include <stdio.h>

class Dummy{
public:
    void do(){ printf("do nothing\n"); }
};

class Task{
public:
    void do(){ printf("do something\n"); }
};

template <class TASK>
void func(TASK &task = Dummy()){
    task.do();
}

int main(){
    func(); // do nothing
    Task task;
    func(task); // do something
}

```

How to make it work?