destructor in .h and .cpp file

I have 'expression must have pointer type' error

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
   so in CCC.h file I have 


public:
	//	Constructor definition. As specified, it takes two arguments,
	//  one for the tax and and tip rate
	RestaurantCheck(double taxRate, double tipRate);
	~RestaurantCheck();  //destructor



so in CCC.cpp file I have
//destructor
RestaurantCheck::~RestaurantCheck(){
	delete taxRate;
}

This doesn't work, what should I do? 
I am assuming taxRate is of type double?
The delete keyword is only for pointer type variables.
http://www.cplusplus.com/doc/tutorial/pointers/
Last edited on
Topic archived. No new replies allowed.