-
What does this mean ??
class AssXXublic Expression{
private:
Expression * lhs;
Variable * rhs;
};
What does the Expression and Variable for the AssXX class means ??
-
They're data types being used to declare pointers. Your API documentation would be able to give you more information. Using code tags would prevent smiley faces.
-
does it works just like how char *data works ???
char comes with c language it self. But Expression and Variable comes from where ??? Is it from a class?? Coz AssXX class and Variable is the child class of Expression.
-
Yes they would work like that. Expression and Variable should be coming from the same place as your class. What library is this class from?
-
What you posted isn't code, or a specific example. It's a general explanation of how some bit of code works... It's a shortcut for "Your expression goes here", and "Your variable goes here".
An Expression evaluates to , or returns, a value. These are Expressions: X++, X=Y, Add(X,Y)
*lhs means "Pointer to Left Hand Side" (Left of the equal-sign.)
*rhs means "Pointer to Right HandSide" (Right of equal-sign.)
BTW - About the unintentional ... When you compose your post, there is a checkbox under additional options to "disable smiles". You also can Preview Post, or go-back and edit it after it's posted.
-
Sure looks like a class declaration to me. Under the smilie face I bet is appropriate code indicating class AssXX is derived publicly from a class called Expression. class AssXX only contains the default constructor, default copy constructor, defaulst assignment operator, default destructor, and two privately declared members one of which is a pointer to the base class Expression called lhs and the other is a pointer to another class called Variable with the pointers name called rhs. The classes called Expression and Variable are "user defined" or other third party defined with declarations elsewhere. This may well a general example of a class declaration because the names used certainly leave something to be desired, IMHO.
Popular pages
Recent additions