diff options
author | Dan Sinclair <dsinclair@chromium.org> | 2016-02-18 14:55:46 -0500 |
---|---|---|
committer | Dan Sinclair <dsinclair@chromium.org> | 2016-02-18 14:55:46 -0500 |
commit | c5ac0202004cd38071a9f6f0d7f3e5d8669ccfbb (patch) | |
tree | 70b68fc5dd773db90b9b2e5d8b14297c85da51c7 /core/include | |
parent | 61046b948a7a15a605147635d317ff3bb27fb452 (diff) | |
download | pdfium-c5ac0202004cd38071a9f6f0d7f3e5d8669ccfbb.tar.xz |
Name the states for fpdf_parser_parser.
Currently the states are numbers, use names instead to make the code
clearer where things are transitioning too.
R=tsepez@chromium.org
Review URL: https://codereview.chromium.org/1715483002 .
Diffstat (limited to 'core/include')
-rw-r--r-- | core/include/fpdfapi/fpdf_parser.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/core/include/fpdfapi/fpdf_parser.h b/core/include/fpdfapi/fpdf_parser.h index de32b1fb37..f57ee5593c 100644 --- a/core/include/fpdfapi/fpdf_parser.h +++ b/core/include/fpdfapi/fpdf_parser.h @@ -450,6 +450,24 @@ class CPDF_Parser { std::set<FX_DWORD> m_ParsingObjNums; friend class CPDF_DataAvail; + + private: + enum class ParserState { + kDefault, + kComment, + kWhitespace, + kString, + kHexString, + kEscapedString, + kXref, + kObjNum, + kPostObjNum, + kGenNum, + kPostGenNum, + kTrailer, + kBeginObj, + kEndObj + }; }; #define FXCIPHER_NONE 0 |