C++ではクラスの定義とそのメンバ関数の定義をヘッダファイルとソースファイルで分割するのが一般的である
### ファイルを分割していない例
c.hpp
#ifndef C_HPP
#define C_HPP
class c {
    private:
    int m_value;
    public:
    int get() {
        return m_value;
    }
    void set(int const value){
        m_value = value;
    }
};
#endif
### ファイルを分割した例
c.hpp
#ifndef C_HPP
#define C_HPP
class c {
    private:
    int m_value;
    public:
    int get();
    void set(int const value);
};
#endif
c.cpp
#include "c.hpp"
int c::get(){
    return m_value;
}
void c::set(int const value){
    m_value = value;
}
インラインで書くこともある
#ifndef C_HPP
#define C_HPP
class c {
    private:
    int m_value;
    public:
    int get();
    void set(int const value);
};
inline int c::get(){
    return m_value;
}
inline void c::set(int const value){
    m_value = value;
}
#endif
bitcoinのソースコードで、基本hppとcppのファイル構造になっていたが、謎が解けた。
 
					 
