Hacker News new | ask | show | jobs
by quinnftw 3577 days ago
Personally I would use a macro such as:

    #define DISALLOW_COPY_AND_ASSIGN(TypeName) \
    TypeName(TypeName&) = delete;              \
    void operator=(TypeName) = delete;
Introducing a virtual base class for disabling copying introduces a vtable and un-needed inheritance.