以下代码编译良好(每行后没有分号)。为什么公共部分下的每行末尾不需要分号?
注意:在每行之后放一个分号也可以,所以在这里使用分号似乎是可选的。
template<typename T>
class Accessor {
    public:
        explicit Accessor(const T& data) : value(data) {}
        Accessor& operator=(const T& data) { value = data; return *this; }
        Accessor& operator=(const Accessor& other) { this->value = other.value; return *this; }
        operator T() const { return value; }
        operator T&() { return value; }
    private:
        Accessor(const Accessor&);
        T value;
};