Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

failure

Name: Anonymous 2009-01-01 23:39


template <class T> class be
{
private:
    bool would;
    bool can;
public:
    be(bool would, bool can) {
        this->would = would;
        this->can = can;
    }
    bool ifCould() {
        return would;
    }
    bool will() {
        return would && can;
    }
};

be<perfect> me(true, false);

Name: Anonymous 2009-01-02 0:04

>>1:19: error: ‘perfect’ was not declared in this scope
>>1:19: error: template argument 1 is invalid
>>1:19: error: invalid type in declaration before ‘(’ token
>>1:19: error: initializer expression list treated as compound expression

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List