| CDT.hpp | | CDT.hpp | |
| | | | |
| skipping to change at line 1643 | | skipping to change at line 1643 | |
| | | | |
| /** | | /** | |
| @brief Get object | | @brief Get object | |
| @return pointer to specified type | | @return pointer to specified type | |
| */ | | */ | |
| template<typename T> T * GetObject() { return (T*)GetPointer(); } | | template<typename T> T * GetObject() { return (T*)GetPointer(); } | |
| | | | |
| /** | | /** | |
| @brief Recursively dump CDT into string | | @brief Recursively dump CDT into string | |
| @param iLevel - left margin | | @param iLevel - left margin | |
|
| | | @param bGlobalFmt - use global object formatting | |
| @return printable string | | @return printable string | |
| */ | | */ | |
|
| STLW::string Dump(UINT_32 iLevel = 0) const; | | STLW::string Dump(UINT_32 iLevel = 0, bool bGlobalFmt = false) const
; | |
| | | | |
| /** | | /** | |
| @brief Alias for RecursiveDump, deprecated | | @brief Alias for RecursiveDump, deprecated | |
| @param iLevel - left margin | | @param iLevel - left margin | |
| @return printable string | | @return printable string | |
| */ | | */ | |
| STLW::string RecursiveDump(UINT_32 iLevel = 0) const; | | STLW::string RecursiveDump(UINT_32 iLevel = 0) const; | |
| | | | |
| /** | | /** | |
| @brief Get value type of object | | @brief Get value type of object | |
| | | | |
| skipping to change at line 1980 | | skipping to change at line 1981 | |
| @brief Unshare shareable container | | @brief Unshare shareable container | |
| */ | | */ | |
| void Unshare(); | | void Unshare(); | |
| | | | |
| /** | | /** | |
| @brief Dump CDT into string | | @brief Dump CDT into string | |
| @param iLevel - level of recursion | | @param iLevel - level of recursion | |
| @param oData - data to dump | | @param oData - data to dump | |
| @param sResult - string to put result in | | @param sResult - string to put result in | |
| */ | | */ | |
|
| static void DumpData(UINT_32 iLevel, UINT_32 iOffset, const CDT & oD
ata, STLW::string & sResult); | | static void DumpData(UINT_32 iLevel, UINT_32 iOffset, const CDT & oD
ata, STLW::string & sResult, bool bGlobalFmt = false); | |
| | | | |
| /** | | /** | |
| @brief Merge two CDT's | | @brief Merge two CDT's | |
| @param oDestination - destination object | | @param oDestination - destination object | |
| @param oSource - source object | | @param oSource - source object | |
| @param eStrategy - Merging strategy | | @param eStrategy - Merging strategy | |
| */ | | */ | |
| static void MergeCDT(CDT & oDestination, const CDT & oSource, const
eMergeStrategy & eStrategy); | | static void MergeCDT(CDT & oDestination, const CDT & oSource, const
eMergeStrategy & eStrategy); | |
| | | | |
| /** | | /** | |
| | | | |
End of changes. 3 change blocks. |
| 2 lines changed or deleted | | 3 lines changed or added | |
|
| CTPP2Compiler.hpp | | CTPP2Compiler.hpp | |
| | | | |
| skipping to change at line 204 | | skipping to change at line 204 | |
| INT_32 PreparePushComplexVariable(const VMDebugInfo & oDebugInfo); | | INT_32 PreparePushComplexVariable(const VMDebugInfo & oDebugInfo); | |
| | | | |
| /** | | /** | |
| @brief Clear after push hash or array variable | | @brief Clear after push hash or array variable | |
| @param oDebugInfo - debug information object | | @param oDebugInfo - debug information object | |
| @return instruction pointer if success, -1 if any error occured | | @return instruction pointer if success, -1 if any error occured | |
| */ | | */ | |
| INT_32 ClearPushComplexVariable(const VMDebugInfo & oDebugInfo); | | INT_32 ClearPushComplexVariable(const VMDebugInfo & oDebugInfo); | |
| | | | |
| /** | | /** | |
|
| | | @brief Push block's variable into stack | |
| | | @param iIdx - stack position | |
| | | @param oDebugInfo - debug information object | |
| | | @return instruction pointer if success, -1 if any error occured | |
| | | */ | |
| | | INT_32 PushBlockVariable(const UINT_32 iIdx, | |
| | | const VMDebugInfo & oDebugInfo = VMDebugInf | |
| | | o()); | |
| | | /** | |
| @brief Push variable into stack | | @brief Push variable into stack | |
| @param szVariableName - variable name | | @param szVariableName - variable name | |
| @param iVariableNameLength - Length of variable name | | @param iVariableNameLength - Length of variable name | |
| @param oDebugInfo - debug information object | | @param oDebugInfo - debug information object | |
| @return instruction pointer if success, -1 if any error occured | | @return instruction pointer if success, -1 if any error occured | |
| */ | | */ | |
| INT_32 PushVariable(CCHAR_P szVariableName, | | INT_32 PushVariable(CCHAR_P szVariableName, | |
| const UINT_32 iVariableNameLength, | | const UINT_32 iVariableNameLength, | |
| const VMDebugInfo & oDebugInfo = VMDebugInfo())
; | | const VMDebugInfo & oDebugInfo = VMDebugInfo())
; | |
| | | | |
| | | | |
| skipping to change at line 307 | | skipping to change at line 315 | |
| @return instruction pointer if success, -1 if any error occured | | @return instruction pointer if success, -1 if any error occured | |
| */ | | */ | |
| INT_32 StartBlock(const STLW::string & sBlockName, | | INT_32 StartBlock(const STLW::string & sBlockName, | |
| const VMDebugInfo & oDebugInfo = VMDebugInfo()); | | const VMDebugInfo & oDebugInfo = VMDebugInfo()); | |
| | | | |
| /** | | /** | |
| @brief End of block | | @brief End of block | |
| @param oDebugInfo - debug information object | | @param oDebugInfo - debug information object | |
| @return instruction pointer if success, -1 if any error occured | | @return instruction pointer if success, -1 if any error occured | |
| */ | | */ | |
|
| INT_32 EndBlock(const VMDebugInfo & oDebugInfo = VMDebugInfo()); | | INT_32 EndBlock(const UINT_32 iDepth, const VMDebugInfo & oDebugInfo | |
| | | = VMDebugInfo()); | |
| | | | |
| | | /** | |
| | | @brief Prepare call block | |
| | | @param oDebugInfo - debug information object | |
| | | @return instruction pointer if success, -1 if any error occured | |
| | | */ | |
| | | INT_32 PrepareCallBlock(const VMDebugInfo & oDebugInfo = VMDebugInfo | |
| | | ()); | |
| | | | |
| // /////////////////////////////////////////////////////////////////
/////////////// | | // /////////////////////////////////////////////////////////////////
/////////////// | |
| | | | |
| /** | | /** | |
| @brief Get system call by id | | @brief Get system call by id | |
| @param szSyscallName - syscall name | | @param szSyscallName - syscall name | |
| @param iSyscallNameLength - Length of syscall name | | @param iSyscallNameLength - Length of syscall name | |
| @return instruction pointer if success, -1 if any error occured | | @return instruction pointer if success, -1 if any error occured | |
| */ | | */ | |
| INT_32 GetSyscallId(CCHAR_P szSyscallName, | | INT_32 GetSyscallId(CCHAR_P szSyscallName, | |
| | | | |
| skipping to change at line 656 | | skipping to change at line 671 | |
| StaticText & oStaticText; | | StaticText & oStaticText; | |
| /** Hash table for calls */ | | /** Hash table for calls */ | |
| HashTable & oHashTable; | | HashTable & oHashTable; | |
| | | | |
| /** Syscall cache */ | | /** Syscall cache */ | |
| STLW::map<STLW::string, UINT_32> mSyscalls; | | STLW::map<STLW::string, UINT_32> mSyscalls; | |
| /** Id of stored 0 to compare */ | | /** Id of stored 0 to compare */ | |
| UINT_32 iZeroId; | | UINT_32 iZeroId; | |
| /** Id of stored 1 to compare */ | | /** Id of stored 1 to compare */ | |
| UINT_32 iOneId; | | UINT_32 iOneId; | |
|
| | | /** Current block stack depth */ | |
| | | UINT_32 iCurrBlockStackDepth; | |
| }; | | }; | |
| | | | |
| } // namespace CTPP | | } // namespace CTPP | |
| #endif // _CTPP2_COMPILER_H__ | | #endif // _CTPP2_COMPILER_H__ | |
| // End. | | // End. | |
| | | | |
End of changes. 3 change blocks. |
| 1 lines changed or deleted | | 21 lines changed or added | |
|
| CTPP2Parser.hpp | | CTPP2Parser.hpp | |
| | | | |
| skipping to change at line 94 | | skipping to change at line 94 | |
| @brief Set parameter names translation map | | @brief Set parameter names translation map | |
| @param oIParamTranslationMap - translation map | | @param oIParamTranslationMap - translation map | |
| */ | | */ | |
| void SetParamMap(const IncludeMapType & oIParamTranslationMap); | | void SetParamMap(const IncludeMapType & oIParamTranslationMap); | |
| | | | |
| /** | | /** | |
| @brief A destructor | | @brief A destructor | |
| */ | | */ | |
| ~CTPP2Parser() throw(); | | ~CTPP2Parser() throw(); | |
| private: | | private: | |
|
| | | typedef STLW::map<STLW::string, UINT_32> BlockArgMapType; | |
| | | | |
| | | typedef STLW::map<STLW::string, UINT_32> BlockArgSizeMapType; | |
| | | | |
| enum eCTPP2Operator { UNDEF = 0, | | enum eCTPP2Operator { UNDEF = 0, | |
| TMPL_var = 1, | | TMPL_var = 1, | |
| TMPL_if = 2, | | TMPL_if = 2, | |
| TMPL_unless = 3, | | TMPL_unless = 3, | |
| TMPL_else = 4, | | TMPL_else = 4, | |
| TMPL_elsif = 5, | | TMPL_elsif = 5, | |
| TMPL_loop = 6, | | TMPL_loop = 6, | |
| TMPL_foreach = 7, | | TMPL_foreach = 7, | |
| TMPL_include = 8, | | TMPL_include = 8, | |
| TMPL_call = 9, | | TMPL_call = 9, | |
| TMPL_udf = 10, | | TMPL_udf = 10, | |
| TMPL_comment = 11, | | TMPL_comment = 11, | |
| TMPL_break = 12, | | TMPL_break = 12, | |
|
| TMPL_block = 13 }; | | TMPL_block = 13, | |
| | | TMPL_verbose = 14 }; | |
| | | | |
| enum eCTPP2ExprOperator { EXPR_UNDEF = 0, | | enum eCTPP2ExprOperator { EXPR_UNDEF = 0, | |
| EXPR_INT_VALUE = 1, | | EXPR_INT_VALUE = 1, | |
| EXPR_FLOAT_VALUE = 2, | | EXPR_FLOAT_VALUE = 2, | |
| EXPR_STRING_VALUE = 3, | | EXPR_STRING_VALUE = 3, | |
| EXPR_VARIABLE = 4, | | EXPR_VARIABLE = 4, | |
| EXPR_FUNCTION = 5, | | EXPR_FUNCTION = 5, | |
| EXPR_BRANCH = 6 }; | | EXPR_BRANCH = 6 }; | |
| | | | |
| enum eCTPP2Relation { R_UNDEF = 0, | | enum eCTPP2Relation { R_UNDEF = 0, | |
| | | | |
| skipping to change at line 251 | | skipping to change at line 256 | |
| /** Foreach flag */ | | /** Foreach flag */ | |
| bool bInForeach; | | bool bInForeach; | |
| /** Recursion level */ | | /** Recursion level */ | |
| INT_32 iRecursionLevel; | | INT_32 iRecursionLevel; | |
| /** Complex variable flag */ | | /** Complex variable flag */ | |
| bool bInsideComplexVariable; | | bool bInsideComplexVariable; | |
| /** No push variable on stack */ | | /** No push variable on stack */ | |
| bool bNoPushVariable; | | bool bNoPushVariable; | |
| /** No map variable */ | | /** No map variable */ | |
| bool bNoMapVariable; | | bool bNoMapVariable; | |
|
| | | /** enable/disable verbose mode */ | |
| | | bool bVerboseMode; | |
| | | /** Block flag */ | |
| | | bool bInBlock; | |
| | | /** Current block arguments */ | |
| | | BlockArgMapType mCurrentBlock; | |
| | | /** Map of number of arguments of blocks */ | |
| | | BlockArgSizeMapType mBlockArgSizes; | |
| | | | |
| // Simple tokens: open and close tags, operators, variables, strings
and numbers //////////////////////////////////////////////////////////////
//////////////////// | | // Simple tokens: open and close tags, operators, variables, strings
and numbers //////////////////////////////////////////////////////////////
//////////////////// | |
| | | | |
| /** | | /** | |
| @brief Open tag ([Tt][Mm][Pp][Ll]) | | @brief Open tag ([Tt][Mm][Pp][Ll]) | |
| @param szData - current stream position | | @param szData - current stream position | |
| @param szEnd - end of stream position | | @param szEnd - end of stream position | |
| @return NULL if sequence not found or pointer to end of sequence | | @return NULL if sequence not found or pointer to end of sequence | |
| */ | | */ | |
| CCharIterator IsOpenTag(CCharIterator szData, CCharIterator szEnd); | | CCharIterator IsOpenTag(CCharIterator szData, CCharIterator szEnd); | |
| | | | |
| skipping to change at line 612 | | skipping to change at line 625 | |
| CCharIterator CommentOperator(CCharIterator szData, CCharIterator sz
End); | | CCharIterator CommentOperator(CCharIterator szData, CCharIterator sz
End); | |
| | | | |
| /** | | /** | |
| @brief Block of code <TMPL_block "blockname"> ..... </TMPL
_block> | | @brief Block of code <TMPL_block "blockname"> ..... </TMPL
_block> | |
| @param szData - current stream position | | @param szData - current stream position | |
| @param szEnd - end of stream position | | @param szEnd - end of stream position | |
| @return NULL if sequence not found or pointer to end of sequence | | @return NULL if sequence not found or pointer to end of sequence | |
| */ | | */ | |
| CCharIterator BlockOperator(CCharIterator szData, CCharIterator szEn
d); | | CCharIterator BlockOperator(CCharIterator szData, CCharIterator szEn
d); | |
| | | | |
|
| | | /** | |
| | | @brief Ignore spaces <TMPL_verbose> ..... </TMPL_verbose&g | |
| | | t; | |
| | | @param szData - current stream position | |
| | | @param szEnd - end of stream position | |
| | | @return NULL if sequence not found or pointer to end of sequence | |
| | | */ | |
| | | CCharIterator VerboseOperator(CCharIterator szData, CCharIterator sz | |
| | | End); | |
| | | | |
| // Other stuff /////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////
//////////////////// | | // Other stuff /////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////
//////////////////// | |
| | | | |
| /** | | /** | |
| @brief Parse CTPP2 template | | @brief Parse CTPP2 template | |
| @param szData - template start | | @param szData - template start | |
| @param szEnd - template end | | @param szEnd - template end | |
| @return 0 if success, -1 if any error occured | | @return 0 if success, -1 if any error occured | |
| */ | | */ | |
| CCharIterator Parse(CCharIterator szData, CCharIterator szEnd); | | CCharIterator Parse(CCharIterator szData, CCharIterator szEnd); | |
| | | | |
| | | | |
| skipping to change at line 661 | | skipping to change at line 682 | |
| @param sParam - parameter to check | | @param sParam - parameter to check | |
| */ | | */ | |
| void CheckParamMap(STLW::string & sParam); | | void CheckParamMap(STLW::string & sParam); | |
| | | | |
| /** | | /** | |
| @brief Get printable operator name | | @brief Get printable operator name | |
| @param oOperator operator type | | @param oOperator operator type | |
| @return printable operator name | | @return printable operator name | |
| */ | | */ | |
| CCHAR_P GetOperatorName(const eCTPP2Operator & oOperator); | | CCHAR_P GetOperatorName(const eCTPP2Operator & oOperator); | |
|
| | | | |
| | | /** | |
| | | @brief Check trailing newline flag | |
| | | @param szData - current stream position | |
| | | @param szEnd - end of stream position | |
| | | @return true, if flag found | |
| | | */ | |
| | | bool CheckTrailingFlag(CCharIterator & szData, CCharIterator szEnd); | |
| | | | |
| | | /** | |
| | | @brief Remove trailing newline(s) | |
| | | @param szData - current stream position | |
| | | @param szEnd - end of stream position | |
| | | */ | |
| | | void RemoveTrailingNewLines(CCharIterator & szData, CCharIterator sz | |
| | | End); | |
| | | | |
| | | /** | |
| | | @brief Parse block arguments | |
| | | @param szData - current stream position | |
| | | @param szEnd - end of stream position | |
| | | @return NULL if sequence not found or pointer to end of sequence | |
| | | */ | |
| | | CCharIterator BlockArgs(CCharIterator szData, CCharIterator szEnd); | |
| | | | |
| | | /** | |
| | | @brief Parse call arguments | |
| | | @param szData - current stream position | |
| | | @param szEnd - end of stream position | |
| | | @param iArgCount - number of arguments | |
| | | @return NULL if sequence not found or pointer to end of sequence | |
| | | */ | |
| | | CCharIterator CallArgs(CCharIterator szData, CCharIterator szEnd, UI | |
| | | NT_32 & iArgCount); | |
| | | | |
| | | /** | |
| | | @brief Set information about blocks | |
| | | @param mIBlockArgSizes - block argument sizes | |
| | | */ | |
| | | void SetBlockArgSizeMap(const BlockArgSizeMapType & mIBlockArgSizes) | |
| | | ; | |
| | | | |
| | | /** | |
| | | @brief Get information about blocks | |
| | | @return mIBlockArgSizes - block argument sizes | |
| | | */ | |
| | | BlockArgSizeMapType GetBlockArgSizeMap() const; | |
| | | | |
| }; | | }; | |
| | | | |
| } // namespace CTPP | | } // namespace CTPP | |
| #endif // _CTPP2_PARSER_H__ | | #endif // _CTPP2_PARSER_H__ | |
| // End. | | // End. | |
| | | | |
End of changes. 5 change blocks. |
| 1 lines changed or deleted | | 72 lines changed or added | |
|
| CTPP2Syntax.h | | CTPP2Syntax.h | |
| | | | |
| skipping to change at line 62 | | skipping to change at line 62 | |
| #define TMPL_ELSIF_TOK "elsif" | | #define TMPL_ELSIF_TOK "elsif" | |
| #define TMPL_UNLESS_TOK "unless" | | #define TMPL_UNLESS_TOK "unless" | |
| #define TMPL_LOOP_TOK "loop" | | #define TMPL_LOOP_TOK "loop" | |
| #define TMPL_FOREACH_TOK "foreach" | | #define TMPL_FOREACH_TOK "foreach" | |
| #define TMPL_UDF_TOK "udf" | | #define TMPL_UDF_TOK "udf" | |
| #define TMPL_INCLUDE_TOK "include" | | #define TMPL_INCLUDE_TOK "include" | |
| #define TMPL_CALL_TOK "call" | | #define TMPL_CALL_TOK "call" | |
| #define TMPL_COMMENT_TOK "comment" | | #define TMPL_COMMENT_TOK "comment" | |
| #define TMPL_BREAK_TOK "break" | | #define TMPL_BREAK_TOK "break" | |
| #define TMPL_BLOCK_TOK "block" | | #define TMPL_BLOCK_TOK "block" | |
|
| | | #define TMPL_VERBOSE_TOK "verbose" | |
| | | | |
| // Loop modifiers | | // Loop modifiers | |
| #define TMPL_GLOBAL_VARS_TOK "__global_vars__" | | #define TMPL_GLOBAL_VARS_TOK "__global_vars__" | |
| #define TMPL_CONTEXT_VARS_TOK "__context_vars__" | | #define TMPL_CONTEXT_VARS_TOK "__context_vars__" | |
| #define TMPL_NO_GLOBAL_VARS_TOK "__no_global_vars__" | | #define TMPL_NO_GLOBAL_VARS_TOK "__no_global_vars__" | |
| #define TMPL_NO_CONTEXT_VARS_TOK "__no_context_vars__" | | #define TMPL_NO_CONTEXT_VARS_TOK "__no_context_vars__" | |
| | | | |
| // Modifiers flags | | // Modifiers flags | |
| #define TMPL_USE_GLOBAL_VARS 0x00000001 | | #define TMPL_USE_GLOBAL_VARS 0x00000001 | |
| #define TMPL_USE_CONTEXT_VARS 0x00000002 | | #define TMPL_USE_CONTEXT_VARS 0x00000002 | |
| | | | |
End of changes. 1 change blocks. |
| 0 lines changed or deleted | | 1 lines changed or added | |
|
| CTPP2SysHeaders.h | | CTPP2SysHeaders.h | |
| | | | |
| skipping to change at line 63 | | skipping to change at line 63 | |
| #define HAVE_TIME_H 1 | | #define HAVE_TIME_H 1 | |
| | | | |
| #define HAVE_UNISTD_H 1 | | #define HAVE_UNISTD_H 1 | |
| | | | |
| #define HAVE_SYSEXITS_H 1 | | #define HAVE_SYSEXITS_H 1 | |
| | | | |
| /* #undef DEBUG_MODE */ | | /* #undef DEBUG_MODE */ | |
| | | | |
| /* #undef NO_STL_STD_NS_PREFIX */ | | /* #undef NO_STL_STD_NS_PREFIX */ | |
| | | | |
|
| #define GETTEXT_SUPPORT 1 | | /* #undef GETTEXT_SUPPORT */ | |
| | | | |
| #define MD5_SUPPORT 1 | | #define MD5_SUPPORT 1 | |
| | | | |
| /* #undef MD5_WITHOUT_OPENSSL */ | | /* #undef MD5_WITHOUT_OPENSSL */ | |
| | | | |
| #define CTPP_FLOAT_PRECISION 12 | | #define CTPP_FLOAT_PRECISION 12 | |
| | | | |
| #define CTPP_ESCAPE_BUFFER_LEN 1024 | | #define CTPP_ESCAPE_BUFFER_LEN 1024 | |
| | | | |
| #define CTPP_MAX_TEMPLATE_RECURSION_DEPTH 1024 | | #define CTPP_MAX_TEMPLATE_RECURSION_DEPTH 1024 | |
| | | | |
| #define ICONV_SUPPORT 1 | | #define ICONV_SUPPORT 1 | |
| | | | |
| #define ICONV_DISCARD_ILSEQ 1 | | #define ICONV_DISCARD_ILSEQ 1 | |
| | | | |
| #define ICONV_TRANSLITERATE 1 | | #define ICONV_TRANSLITERATE 1 | |
| | | | |
|
| #define CTPP_VERSION "2.7.0" | | #define CTPP_VERSION "2.7.1" | |
| #define CTPP_IDENT "Dzoraget" | | #define CTPP_IDENT "Dzoraget" | |
| #define CTPP_MASTER_SITE_URL "http://ctpp.havoc.ru/" | | #define CTPP_MASTER_SITE_URL "http://ctpp.havoc.ru/" | |
| | | | |
| /* #undef THROW_EXCEPTION_IN_COMPARATORS */ | | /* #undef THROW_EXCEPTION_IN_COMPARATORS */ | |
| | | | |
| #endif /* _CTPP2_SYS_HEADERS_H__ */ | | #endif /* _CTPP2_SYS_HEADERS_H__ */ | |
| /* End. */ | | /* End. */ | |
| | | | |
End of changes. 2 change blocks. |
| 2 lines changed or deleted | | 2 lines changed or added | |
|
| CTPP2VMArgStack.hpp | | CTPP2VMArgStack.hpp | |
| | | | |
| skipping to change at line 78 | | skipping to change at line 78 | |
| class CTPP2DECL VMArgStack | | class CTPP2DECL VMArgStack | |
| { | | { | |
| public: | | public: | |
| /** | | /** | |
| @brief Constructor | | @brief Constructor | |
| @param iIMaxStackSize - maximal stack size | | @param iIMaxStackSize - maximal stack size | |
| */ | | */ | |
| VMArgStack(const INT_32 iIMaxStackSize = 4096); | | VMArgStack(const INT_32 iIMaxStackSize = 4096); | |
| | | | |
| /** | | /** | |
|
| | | @brief Save base pointer | |
| | | */ | |
| | | void SaveBasePointer(); | |
| | | | |
| | | /** | |
| | | @brief Restore previous base pointer | |
| | | */ | |
| | | void RestoreBasePointer(); | |
| | | | |
| | | /** | |
| @brief Get stack usage factor | | @brief Get stack usage factor | |
| @return stack depth | | @return stack depth | |
| */ | | */ | |
| INT_32 GetSize() const; | | INT_32 GetSize() const; | |
| | | | |
| /** | | /** | |
| @brief Push element into stack | | @brief Push element into stack | |
| @param oCDT - element to push | | @param oCDT - element to push | |
| @return stack depth | | @return stack depth | |
| */ | | */ | |
| | | | |
| skipping to change at line 143 | | skipping to change at line 153 | |
| | | | |
| /** | | /** | |
| @brief Copy operator | | @brief Copy operator | |
| */ | | */ | |
| VMArgStack & operator=(const VMArgStack & oRhs); | | VMArgStack & operator=(const VMArgStack & oRhs); | |
| | | | |
| /** Maximal stack size */ | | /** Maximal stack size */ | |
| const INT_32 iMaxStackSize; | | const INT_32 iMaxStackSize; | |
| /** Current stack size */ | | /** Current stack size */ | |
| INT_32 iStackPointer; | | INT_32 iStackPointer; | |
|
| /* * unused | | /** Base pointers */ | |
| INT_32 iBasePointer; */ | | STLW::vector<INT_32> vBasePointers; | |
| | | | |
| /** Stack array */ | | /** Stack array */ | |
| CDT * aStack; | | CDT * aStack; | |
| | | | |
| /** | | /** | |
| @brief Get stack frame from top of stack | | @brief Get stack frame from top of stack | |
| @param iTopOffset - offset of frame | | @param iTopOffset - offset of frame | |
| @return pointer to start of frame | | @return pointer to start of frame | |
| */ | | */ | |
| inline CDT * GetStackFrame(const INT_32 iTopOffset = 0) { return &a
Stack[iStackPointer + iTopOffset]; } | | inline CDT * GetStackFrame(const INT_32 iTopOffset = 0) { return &a
Stack[iStackPointer + iTopOffset]; } | |
| | | | |
End of changes. 2 change blocks. |
| 2 lines changed or deleted | | 12 lines changed or added | |
|
| CTPP2VMOpcodes.h | | CTPP2VMOpcodes.h | |
| | | | |
| skipping to change at line 147 | | skipping to change at line 147 | |
| #define RJODD (RJXX | FL_NPF) // Jump if Result is ODD | | #define RJODD (RJXX | FL_NPF) // Jump if Result is ODD | |
| | | | |
| // Other ops. ////////// 0x-8-X---- ///////////////////////////////////////
///////////////////////// | | // Other ops. ////////// 0x-8-X---- ///////////////////////////////////////
///////////////////////// | |
| #define CLEAR 0x08010000 // Clear register | | #define CLEAR 0x08010000 // Clear register | |
| #define OUTPUT 0x08020000 // Direct output a value to output coll
ector | | #define OUTPUT 0x08020000 // Direct output a value to output coll
ector | |
| #define REPLACE 0x08030000 // Replace variable in stack or registe
r | | #define REPLACE 0x08030000 // Replace variable in stack or registe
r | |
| #define EXIST 0x08040000 // Check existence of operand | | #define EXIST 0x08040000 // Check existence of operand | |
| #define REPLINT 0x08050000 // Replace ARRAY variable in stack with
it's element | | #define REPLINT 0x08050000 // Replace ARRAY variable in stack with
it's element | |
| #define REPLSTR 0x08060000 // Replace HASH variable in stack with
it's element | | #define REPLSTR 0x08060000 // Replace HASH variable in stack with
it's element | |
| #define XCHG 0x08070000 // Swap 2 values | | #define XCHG 0x08070000 // Swap 2 values | |
|
| #define DEFINED 0x08080000 // check undef value | | #define DEFINED 0x08080000 // Check undef value | |
| | | #define SAVEBP 0x08090000 // Save base pointer | |
| | | #define RESTBP 0x080A0000 // Restore base pointer | |
| | | | |
| // Sources ///////////// 0x-------X ///////////////////////////////////////
/////////////////////////// | | // Sources ///////////// 0x-------X ///////////////////////////////////////
/////////////////////////// | |
| #define ARG_SRC_AR 0x00000000 // AR is source register | | #define ARG_SRC_AR 0x00000000 // AR is source register | |
| #define ARG_SRC_BR 0x00000001 // BR is source register | | #define ARG_SRC_BR 0x00000001 // BR is source register | |
| #define ARG_SRC_CR 0x00000002 // CR is source register | | #define ARG_SRC_CR 0x00000002 // CR is source register | |
| #define ARG_SRC_DR 0x00000003 // DR is source register | | #define ARG_SRC_DR 0x00000003 // DR is source register | |
| #define ARG_SRC_ER 0x00000004 // ER is source register | | #define ARG_SRC_ER 0x00000004 // ER is source register | |
| #define ARG_SRC_FR 0x00000005 // FR is source register | | #define ARG_SRC_FR 0x00000005 // FR is source register | |
| #define ARG_SRC_GR 0x00000006 // GR is source register | | #define ARG_SRC_GR 0x00000006 // GR is source register | |
| #define ARG_SRC_HR 0x00000007 // HR is source register | | #define ARG_SRC_HR 0x00000007 // HR is source register | |
| | | | |
End of changes. 1 change blocks. |
| 1 lines changed or deleted | | 3 lines changed or added | |
|