Ignore:
Timestamp:
Dec 31, 2017, 7:22:14 PM (15 months ago)
Author:
cameron
Message:

Supporting multiple alphabets in RE compilation - initial check-in

File:
1 edited

Legend:

Unmodified
Added
Removed
  • icGREP/icgrep-devel/icgrep/cc/alphabet.h

    r5800 r5816  
    2222public:
    2323    const std::string & getName() const { return mAlphabetName;}
     24    virtual const unsigned getSize() const = 0;
    2425    enum class ClassTypeId : unsigned {UnicodeMappableAlphabet, CodeUnitAlphabet, MultiplexedAlphabet};
    2526    inline ClassTypeId getClassTypeId() const {
     
    5758    unsigned fromUnicode(const UCD::codepoint_t ucp) const;
    5859
     60    const unsigned getSize() const override {return mUnicodeCommon + mAboveCommon.size();}
     61
    5962protected:
    6063    UCD::codepoint_t mCharSet;
     
    7174    static inline bool classof(const void *) {return false;}
    7275    uint8_t getCodeUnitBitWidth() { return mCodeUnitBits;}
    73    
     76    const unsigned getSize() const override {return 1<<mCodeUnitBits;}
     77
    7478private:
    7579    uint8_t mCodeUnitBits;
Note: See TracChangeset for help on using the changeset viewer.