Changeset 10878 for trunk


Ignore:
Timestamp:
05/27/11 17:27:10 (13 years ago)
Author:
tbretz
Message:
Use GetText in pointer arithmetics.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/src/EventImp.h

    r10877 r10878  
    7272    std::string       GetString() const;
    7373
     74    // FIXME: Do we need a range check?
     75
    7476    template<typename T>
    7577        T Get(int offset=0) const { return *reinterpret_cast<const T*>(GetText()+offset); }
    7678
    7779    template<typename T>
    78         T *Ptr(int offset=0) const { return *reinterpret_cast<const T*>(GetData()+offset); }
     80        T *Ptr(int offset=0) const { return *reinterpret_cast<const T*>(GetText()+offset); }
    7981};
    8082
Note: See TracChangeset for help on using the changeset viewer.