c++ - Syntax explanation -
in code:
struct tagpaint { }paint,//<<<--------------what's (paint)? *ppaint;//<<<-------------and this(*ppaint)?
i mean declare variable name paint of type tagpaint , pointer called ppaint tagpaint?
thanks.
paint variable of type tagpaint. ppaint pointer type tagpaint. if want them define types, need:
typedef struct tagpaint { ... } paint, * ppaint;
but c usage - should not writing code in c++. , in c, defining type hides fact pointer considered bad style.
Comments
Post a Comment