title: Compiling a Class with GCC
body: <p>Hey all im not sure if ive made a syntactical error hear but ive made a class and get this error when i try to compile it....</p>
  
  <pre><code>dining.h:7:1: error: unknown type name ‘class’
  dining.h:7:17: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘{’ token
  </code></pre>
  
  <p>it works fine with g++ but i have to use gcc...</p>
  
  <p>this is the problem code..</p>
  
  <pre><code>#ifndef DINING_H
  #define DINING_H
  
  class DiningSet {
  
      public:
          DiningSet();
          ~DiningSet();
          void getSize(); // accepts X and Y dimentions of the table (in metres)
          //void surfaceArea(int,int);    // Calculates Surface Area of table (in square metres)
          void numChairs();   // accepts number of chairs
          void cushionColour();   // accepts a cushion colour
          void woodType();    // accepts wood type
          void priceComp();   // computes a price of set
          void purchaseDet(); // displays details of purchase
          void purchasePrice();   // displays price of purchace
  
      private:
          int X, Y; // Dimentions of table
          float Surface;
          int chairs; // Number of chairs
          char colour; // colour of cushion (should be dynamic array)
          char wood;
          float totalPrice;   
  };
  
  
  #endif
  </code></pre>