add Span class and use it from TextLoader
This commit is contained in:
1 parent
b64b9bed23
commit
cdae9e51ae
5 files changed
+29
-14
No files matched your search
@@ -4,6 +4,7 @@
|
||||
#include <stdint.h>
|
||||
#include <list>
|
||||
#include <memory>
|
||||
#include "Span.h"
|
||||
|
||||
class TextLoader
|
||||
{
|
||||
@@ -34,14 +35,10 @@ public:
|
||||
auto end() { return m_lines->end(); }
|
||||
bool get_eol_at_eof() { return m_eol_at_eof; }
|
||||
|
||||
typedef std::pair<uint8_t *, uint32_t> LineIndexPair;
|
||||
typedef std::list<LineIndexPair> LineIndexPairList;
|
||||
typedef std::shared_ptr<LineIndexPairList> LineIndexPairListRef;
|
||||
|
||||
protected:
|
||||
int m_line_endings;
|
||||
bool m_eol_at_eof;
|
||||
LineIndexPairListRef m_lines;
|
||||
std::shared_ptr<std::list<Span>> m_lines;
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in new issue
Block a user