<commit_before>#ifndef LIQUIDOP_H
#define LIQUIDOP_H

#include <boost/shared_ptr.hpp>
#include "sentence.h"

class LiquidOp : public Sentence {
public:
    LiquidOp(boost::shared_ptr<Sentence> sentence);
    LiquidOp(const LiquidOp& liq);
    virtual ~LiquidOp();

    friend void swap(LiquidOp& a, LiquidOp& b);
    LiquidOp& operator=(LiquidOp b);

    boost::shared_ptr<Sentence> sentence();
    boost::shared_ptr<const Sentence> sentence() const;

    void setSentence(boost::shared_ptr<Sentence> s);
private:
    boost::shared_ptr<Sentence> s_;

    virtual Sentence* doClone() const;
    virtual bool doEquals(const Sentence& s) const;
    virtual void doToString(std::stringstream& str) const;
    virtual int doPrecedence() const;

    virtual void visit(SentenceVisitor& v) const;
    virtual bool doContains(const Sentence& s) const;
};

// IMPLEMENTATION

inline LiquidOp::LiquidOp(boost::shared_ptr<Sentence> sentence) : s_(sentence) {};
inline LiquidOp::LiquidOp(const LiquidOp& liq) : s_(liq.s_) {}; // shallow copy
inline LiquidOp::~LiquidOp() {};

inline void swap(LiquidOp& a, LiquidOp& b) {
    using std::swap;
    swap(a.s_, b.s_);
}

inline LiquidOp& LiquidOp::operator=(LiquidOp b) {
    swap(*this, b);
    return *this;
};
inline const boost::shared_ptr<Sentence> LiquidOp::sentence() {return s_;};
inline boost::shared_ptr<const Sentence> LiquidOp::sentence() const {return s_;};

inline void LiquidOp::setSentence(boost::shared_ptr<Sentence> s) {s_ = s;}

// private members

inline Sentence* LiquidOp::doClone() const { return new LiquidOp(*this); }
inline bool LiquidOp::doEquals(const Sentence& s) const {
    const LiquidOp *liq = dynamic_cast<const LiquidOp*>(&s);<commit_msg>oops, small bug fix<commit_after>#ifndef LIQUIDOP_H
#define LIQUIDOP_H

#include <boost/shared_ptr.hpp>
#include "sentence.h"

class LiquidOp : public Sentence {
public:
    LiquidOp(boost::shared_ptr<Sentence> sentence);
    LiquidOp(const LiquidOp& liq);
    virtual ~LiquidOp();

    friend void swap(LiquidOp& a, LiquidOp& b);
    LiquidOp& operator=(LiquidOp b);

    boost::shared_ptr<Sentence> sentence();
    boost::shared_ptr<const Sentence> sentence() const;

    void setSentence(boost::shared_ptr<Sentence> s);
private:
    boost::shared_ptr<Sentence> s_;

    virtual Sentence* doClone() const;
    virtual bool doEquals(const Sentence& s) const;
    virtual void doToString(std::stringstream& str) const;
    virtual int doPrecedence() const;

    virtual void visit(SentenceVisitor& v) const;
    virtual bool doContains(const Sentence& s) const;
};

// IMPLEMENTATION

inline LiquidOp::LiquidOp(boost::shared_ptr<Sentence> sentence) : s_(sentence) {};
inline LiquidOp::LiquidOp(const LiquidOp& liq) : s_(liq.s_) {}; // shallow copy
inline LiquidOp::~LiquidOp() {};

inline void swap(LiquidOp& a, LiquidOp& b) {
    using std::swap;
    swap(a.s_, b.s_);
}

inline LiquidOp& LiquidOp::operator=(LiquidOp b) {
    swap(*this, b);
    return *this;
};
inline boost::shared_ptr<Sentence> LiquidOp::sentence() {return s_;};
inline boost::shared_ptr<const Sentence> LiquidOp::sentence() const {return s_;};

inline void LiquidOp::setSentence(boost::shared_ptr<Sentence> s) {s_ = s;}

// private members

inline Sentence* LiquidOp::doClone() const { return new LiquidOp(*this); }
inline bool LiquidOp::doEquals(const Sentence& s) const {
    const LiquidOp *liq = dynamic_cast<const LiquidOp*>(&s);
{'fraction_non_alphanumeric': 0.13561804335090802, 'fraction_numerical': 0.0, 'mean_word_length': 5.359404096834265, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 25, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1851925', 'n_tokens_mistral': 1241, 'n_tokens_neox': 1142, 'n_words': 285}