I have a class structure where I have some member variables declared like this:
/* HEADER */
#ifndef SRC_HEADER_H
#define SRC_HEADER_H
class Service {
private:
typedef boost::multi_index_container<...> Checkpoints;
Checkpoints checkpoints_ GUARDED_BY(mutex_);
};
#endif
Then I have the source file with the implementation:
#include "src/header.h"
/* some functions which use `checkpoints_` */
Is there a way I could move the typedef from the header file to the source file and keep the member checkpoints_
there in the header file only? I am trying to make the header file lighter since this multi_index_container
might become a heavy container with repercussions on compile time.