Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(109)

Unified Diff: xfa/src/fxfa/src/fm2js/xfa_simpleexpression.h

Issue 1764473002: Some cleanup for xfa_expression/xfa_simpleexpression (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: address nits Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « xfa/src/fxfa/src/fm2js/xfa_expression.cpp ('k') | xfa/src/fxfa/src/fm2js/xfa_simpleexpression.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: xfa/src/fxfa/src/fm2js/xfa_simpleexpression.h
diff --git a/xfa/src/fxfa/src/fm2js/xfa_simpleexpression.h b/xfa/src/fxfa/src/fm2js/xfa_simpleexpression.h
index bc84ab784df248e5059c94542c4efd457a80513b..df27a630b8f14504059dfc8698b9dd0658d2e307 100644
--- a/xfa/src/fxfa/src/fm2js/xfa_simpleexpression.h
+++ b/xfa/src/fxfa/src/fm2js/xfa_simpleexpression.h
@@ -7,6 +7,8 @@
#ifndef XFA_SRC_FXFA_SRC_FM2JS_XFA_SIMPLEEXPRESSION_H_
#define XFA_SRC_FXFA_SRC_FM2JS_XFA_SIMPLEEXPRESSION_H_
+#include <memory>
+
#include "core/include/fxcrt/fx_basic.h"
#include "xfa/src/fxfa/src/fm2js/xfa_lexer.h"
@@ -109,11 +111,10 @@ class CXFA_FMUnaryExpression : public CXFA_FMSimpleExpression {
CXFA_FMUnaryExpression(FX_DWORD line,
XFA_FM_TOKEN op,
CXFA_FMSimpleExpression* pExp);
- ~CXFA_FMUnaryExpression() override;
void ToJavaScript(CFX_WideTextBuf& javascript) override;
protected:
- CXFA_FMSimpleExpression* m_pExp;
+ std::unique_ptr<CXFA_FMSimpleExpression> m_pExp;
};
class CXFA_FMBinExpression : public CXFA_FMSimpleExpression {
@@ -122,12 +123,11 @@ class CXFA_FMBinExpression : public CXFA_FMSimpleExpression {
XFA_FM_TOKEN op,
CXFA_FMSimpleExpression* pExp1,
CXFA_FMSimpleExpression* pExp2);
- ~CXFA_FMBinExpression() override;
void ToJavaScript(CFX_WideTextBuf& javascript) override;
protected:
- CXFA_FMSimpleExpression* m_pExp1;
- CXFA_FMSimpleExpression* m_pExp2;
+ std::unique_ptr<CXFA_FMSimpleExpression> m_pExp1;
+ std::unique_ptr<CXFA_FMSimpleExpression> m_pExp2;
};
class CXFA_FMAssignExpression : public CXFA_FMBinExpression {
« no previous file with comments | « xfa/src/fxfa/src/fm2js/xfa_expression.cpp ('k') | xfa/src/fxfa/src/fm2js/xfa_simpleexpression.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698