error C2664: 'Stack<type>::equal' : cannot convert parameter 1 from 'char' to 'Stack<type> &'
<p>i am working on this program ,but i am receiving 2 errors , i cant know what they mean or how i fix them ....
the program should read any equation as a+b-c or (a+b)-c ...etc
and check if the  parenthesis match or not 
here is the code </p>

<pre><code>// A simple Integer stack, Array based
#include &lt;string&gt;
#include &lt;iostream&gt;
#define STACK_MAX 100
#define equation

using namespace std;
template &lt;typename type&gt;
class Stack {

private:
    type        data[STACK_MAX];
    int        size;

public:
    Stack();
    ~Stack() { }   // Destructor
    int top();
    void push(int d) ;
    void pop() ;
    int is_full ();
    int is_empty () ;
    void equal( Stack&amp; entry) ;
};
template &lt;typename type &gt; int Stack&lt;type&gt;::is_full () {
    return ( STACK_MAX &gt;= size );
}
template &lt;typename type &gt; int Stack&lt;type&gt;::is_empty () {
    return ( STACK_MAX == 0 );
}
template &lt;typename type&gt;  Stack &lt;type&gt;::Stack() {
    size = 0;
}
template &lt;typename type &gt; int Stack&lt; type &gt;:: top() {

    if (is_empty ()) {
        printf("Error: stack empty\n");
        return -1;
    }
    return data[size-1];
}
template &lt;typename type &gt; void Stack &lt;type&gt;::push (int d) {

    if (! is_full () ) {
        data[size++] = d;
    } else {
        printf("Error: stack full\n");
    }
}
template &lt; typename type &gt; void Stack &lt;type&gt;::pop() {

    if (size == 0) {
        printf("Error: stack empty\n");
    } else {
        size--;
    }
}
template &lt;typename type &gt; void Stack &lt;type&gt; ::equal ( Stack&amp; entry ) {
    std::string&amp; equation ;
    char left = '(' ;
    char right= ')' ;
    Stack &lt;type&gt; x ;
    string::size_type a ;
    char next ;
    next = entry ;
    bool failed = false ;
    for ( a= 0 ; ! equation.length() ; ++a) {
        next = equation[a] ;
        if ( next == left ) {
            x.push (next);
        } else {
            if (x.is_empty()) {
                x.pop () ;
            } else {
                failed = true ;
            }
        }

    }
    if ( a == 0) {
        cout &lt;&lt; " No parenthesis"&lt;&lt; endl ;
    } else if ( x.top () == left ) {
        cout &lt;&lt; "Parenthesis don’t match. Missing right parenthesis" &lt;&lt; endl ;
    } else if ( x.top () == right ) {
        cout &lt;&lt; "Parenthesis don’t match. Missing left parenthesis " &lt;&lt; endl ;
    } else {
        cout &lt;&lt; "Matching parenthesis" &lt;&lt; endl ;
    }

}


int main() {

    Stack &lt;char&gt; equation2 ;
    char b ;
    cout &lt;&lt; " please enter your equation " &lt;&lt; endl ;
    for (int i =0 ; i&lt; 100 ; i++ ) {

        cin &gt;&gt; b ;
        equation2.equal(b) ;
    }


    system ("pause") ;


    return 0;
}
</code></pre>

<p>and here are the errors </p>

<pre><code>    2   IntelliSense: a reference of type "Stack&lt;char&gt; &amp;" (not const-qualified) cannot be initialized with a value of type "char"   c:\users\mike\documents\visual studio 2010\projects\stack\stack\stack.cpp   101
   Error    1   error C2664: 'Stack&lt;type&gt;::equal' : cannot convert parameter 1 from 'char' to 'Stack&lt;type&gt; &amp;'   c:\users\mike\documents\visual studio 2010\projects\stack\stack\stack.cpp   101
</code></pre>
