title: How to instantiate an object witn an enum parameter in c++?
body: <p>I am trying to instantiate an object 'Bug bug' with 3 parameters and one of them is enumerator. Here is my class:</p>
  
  <pre><code> class Bug 
  {
  private:
      int Id;
      string description;
      enum severity { low, medium, severe} s;
  
  public:
      Bug(void);
       Bug(int id, string descr, severity x)
                :Id(id), description(descr), s(x)
       {}
  
      void printDetails()
      {
         cout&lt;&lt; "Severity level:" &lt;&lt;s&lt;&lt; " Description: " &lt;&lt;description&lt;&lt;" ID= " 
         &lt;&lt;Id&lt;&lt; endl;
      }
     ~Bug(void);
  </code></pre>
  
  <p>};</p>
  
  <p>this is my main.cpp:</p>
  
  <pre><code>    #include "Bug.h"
      int main(){
  
      Bug bg(3,"a", low);//Error message: identifier "low" is undefined
  
       return 0;
      }
  </code></pre>
  
  <p>when I added this line to the main</p>
  
  <pre><code>    enum severity { low, medium, severe};
  </code></pre>
  
  <p>the error message has changed to this:</p>
  
  <pre><code>      Bug bg(3,"a", low);//Error message: no instance of constructor "Bug::bug" matches the argument list
  </code></pre>
  
  <p>Any ideas how to do this right?</p>