diff options
author | Dan Sinclair <dsinclair@chromium.org> | 2017-05-16 12:17:50 -0400 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2017-05-16 16:29:23 +0000 |
commit | c0d358ad234843a524a1bcc2a439f08ad0c64aa1 (patch) | |
tree | dfb046a476f5dece9f76764415e6f297591f1829 /xfa/fxfa/fm2js/xfa_lexer.h | |
parent | 2eef64cba5c8e08a9e625f4aba5a7fbdc8e62bad (diff) | |
download | pdfium-c0d358ad234843a524a1bcc2a439f08ad0c64aa1.tar.xz |
Update formcalc return types
Update return types to be bools instead of ints. Make some methods private.
Change-Id: I5d55c48a861f90e9bd116ef835c11cdb515002a6
Reviewed-on: https://pdfium-review.googlesource.com/5553
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Nicolás Peña <npm@chromium.org>
Diffstat (limited to 'xfa/fxfa/fm2js/xfa_lexer.h')
-rw-r--r-- | xfa/fxfa/fm2js/xfa_lexer.h | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/xfa/fxfa/fm2js/xfa_lexer.h b/xfa/fxfa/fm2js/xfa_lexer.h index 0db9de58a9..7de76d7a62 100644 --- a/xfa/fxfa/fm2js/xfa_lexer.h +++ b/xfa/fxfa/fm2js/xfa_lexer.h @@ -108,21 +108,23 @@ class CXFA_FMLexer { ~CXFA_FMLexer(); CXFA_FMToken* NextToken(); - const wchar_t* Number(CXFA_FMToken* t, const wchar_t* p); - const wchar_t* String(CXFA_FMToken* t, const wchar_t* p); - const wchar_t* Identifiers(CXFA_FMToken* t, const wchar_t* p); - const wchar_t* Comment(const wchar_t* p); - XFA_FM_TOKEN IsKeyword(const CFX_WideStringC& p); + bool HasError() const; + void SetCurrentLine(uint32_t line) { m_uCurrentLine = line; } void SetToken(std::unique_ptr<CXFA_FMToken> pToken) { m_pToken = std::move(pToken); } - const wchar_t* SavePos() { return m_ptr; } - void RestorePos(const wchar_t* pPos) { m_ptr = pPos; } - void Error(const wchar_t* msg, ...); - bool HasError() const; + + const wchar_t* GetPos() { return m_ptr; } + void SetPos(const wchar_t* pPos) { m_ptr = pPos; } private: + const wchar_t* Number(CXFA_FMToken* t, const wchar_t* p); + const wchar_t* String(CXFA_FMToken* t, const wchar_t* p); + const wchar_t* Identifiers(CXFA_FMToken* t, const wchar_t* p); + const wchar_t* Comment(const wchar_t* p); + XFA_FM_TOKEN IsKeyword(const CFX_WideStringC& p); + void Error(const wchar_t* msg, ...); std::unique_ptr<CXFA_FMToken> Scan(); const wchar_t* m_ptr; |