User Profile

Collapse

Profile Sidebar

Collapse
pbgcs
pbgcs
Last Activity: Apr 22 '09, 01:55 AM
Joined: Aug 13 '08
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • pbgcs
    replied to why are constructors evil ?
    in C
    Hi , can you answer my last question ? Thanks!...
    See more | Go to post

    Leave a comment:


  • pbgcs
    replied to why are constructors evil ?
    in C
    Hi,
    Thanks a lot! Your post is really helpful in improving my understanding. I understood now that it is so as it can be passed only as a reference/pointer .Also we are assuming that once an instance is created we wont be making a copy of it right. Sorry im just messed up but i think i have read about some design pattern ( its been some time i read so i forgot) says having clone() to create an exact replica of the object. Is it the correct...
    See more | Go to post

    Leave a comment:


  • pbgcs
    started a topic why are constructors evil ?
    in C

    why are constructors evil ?

    I just downloaded chrome source code and saw the following macros

    // A macro to disallow the copy constructor and operator= functions
    // This should be used in the private: declarations for a class
    #define DISALLOW_COPY_A ND_ASSIGN(TypeN ame) \
    TypeName(const TypeName&); \
    void operator=(const TypeName&)

    // An older, deprecated, politically incorrect name for the above....
    See more | Go to post
No activity results to display
Show More
Working...