Files
harbour-core/harbour/include/hbpcode.h
Przemyslaw Czerpak 26a11bd859 2009-03-21 16:07 UTC+0100 Przemyslaw Czerpak (druzus/at/priv.onet.pl)
* harbour/bin/hb-func.sh
    ! restored default optimization flag (-O3) in hb* scripts

  * harbour/harbour.spec
    ! fixed recent modification

  * harbour/contrib/rddads/ads1.c
  * harbour/contrib/rddads/adsfunc.c
  * harbour/contrib/hbmisc/strfmt.c
  * harbour/contrib/hbcrypt/sha1.c
    ! fixed wrongly used C reference operator

  * harbour/contrib/hbwin/win_prn2.c
  * harbour/contrib/hbwin/wapi_commctrl.c
  * harbour/source/vm/maindllp.c
    ! fixes for unicode builds

  * harbour/include/std.ch
    + added SET TIME FORMAT [TO] <f>

  * harbour/include/set.ch
  * harbour/include/hbset.h
  * harbour/source/vm/set.c
    + added _SET_TIMEFORMAT
      The folowing modifiers are supported:
         hh - hours
         mm - minutes
         ss - seconds
         fff - fraction part of seconds
         p - 1-st letter from PM / AM signature. When used time is shown
             in 12 hour format otherwise 24 hour format is used
      ex: Set( __SET_TIMEFORMAT, "hh:mm pm" )
      default _SET_TIMEFORMAT value is "hh:mm:ss:fff"
    + added C function: char * hb_setGetTimeFormat( void );

  * harbour/include/hbpp.h
  * harbour/source/pp/ppcore.c
    + added support for timestamp constant values in the form:
         t"YYYY-MM-DD HH:MM:SS.fff"
      The exact accepted timestamp pattern is is:
         YYYY-MM-DD [H[H][:M[M][:S[S][.f[f[f[f]]]]]]] [PM|AM]
      i.e.:
         tValue := t"2009-03-21 5:31:45.437 PM"
      or:
         YYYY-MM-DDT[H[H][:M[M][:S[S][.f[f[f[f]]]]]]] [PM|AM]
      with literal "T" as date and time part delimiters (XML timestamp
      format), i.e.:
         tValue := t"2009-03-21T17:31:45.437"
      The folowing characters can be used as date delimiters: "-", "/", "."
      if PM or AM is used HH is in range < 1 : 12 > otherwise
      in range < 0 : 23 >

  * harbour/source/compiler/complex.c
  * harbour/source/compiler/harbour.y
  * harbour/source/compiler/harbour.yyc
  * harbour/source/compiler/harbour.yyh
    + added support for t"YYYY-MM-DD HH:MM:SS.fff" time stamp constant
      to compiler
    + added support for VFP datetime constant values:
         { ^ [ YYYY-MM-DD [,] ] [ HH[:MM[:SS][.FFF]] [AM|PM] ] }
      The following characters can be used as date delimiters: "-", "/".
      Dot "." as date delimiter is not supported.
      There is no limit on number of characters in YYYY, MM, DD, HH, MM,
      SS, FFF parts. Important is only their value. This is the format
      in semi PP notation:
         { ^ <YEAR> <sep:/-> <MONTH> <sep:/-> <DAY> [[<sep2:,>]
           [ <HOUR> [ : <MIN> [ : <SEC> [ . <FRAQ> ] ] ] [AM|PP] ] }
      In practice it allows to also parse xHarbour datetime constant
      values with compatible conditions though xHarbour support onlu "/"
      as date delimiter.
      NOTE: there is one important difference to VFP and xHarbour in
      decoding above format. In VFP and xHarbour when date part is
      missing then it's set by default to: 1899-12-30 so this code:
         { ^ 12:00 }
      gived the same results as:
         { ^ 1899/12/30 12:00 }
      Harbour does not set any default date value when timestamp
      constant value contains only time part.
      If you want we can change it for strict VFP compatiblity.
      Now this extension is enabled by default for testing. In the future
      it will be probably covered by HB_COMPAT_FOXPRO macro.

  * harbour/source/macro/macro.yyc
  * harbour/source/macro/macro.y
  * harbour/source/macro/macro.yyh
  * harbour/source/macro/macrolex.c
    + added support for t"YYYY-MM-DD HH:MM:SS.fff" time stamp constant
      to macro compiler

  * harbour/include/hbmacro.h
  * harbour/source/vm/macro.c
    + added new function:
      void hb_macroGenPushTimeStamp( LONG lDate, LONG lTime, HB_COMP_DECL );

  * harbour/include/hberrors.h
  * harbour/source/compiler/hbgenerr.c
    + added new compile time error: "Invalid timestamp constant '%s'"

  * harbour/source/compiler/cmdcheck.c
    * use Harbour API timestamp functions instead of calling system
      functions

  * harbour/include/hbpcode.h
  * harbour/source/compiler/hbfix.c
  * harbour/source/compiler/hbpcode.c
  * harbour/source/compiler/hbdead.c
  * harbour/source/compiler/genc.c
  * harbour/source/compiler/gencc.c
  * harbour/source/compiler/hblbl.c
  * harbour/source/compiler/hbstripl.c
  * harbour/source/compiler/hbopt.c
    + added new PCODE HB_P_PUSHTIMESTAMP (replaced one unused PCODE value)
      to store timestamp constant values in the PCODE

  * harbour/include/hbcomp.h
  * harbour/source/compiler/hbmain.c
    + added new function:
      void hb_compGenPushTimeStamp( LONG lDate, LONG lTime, HB_COMP_DECL );

  * harbour/include/hbexprop.h
  * harbour/source/common/expropt1.c
    + added new C functions:
      HB_EXPR_PTR hb_compExprNewTimeStamp( LONG, LONG, HB_COMP_DECL );

  * harbour/include/hbexprb.c
  * harbour/include/hbcompdf.h
  * harbour/source/common/expropt2.c
    + added timestamp expressions support
    + added compile time optimization for timestamp expressions
    * updated function optimization for timestamp expressions

  * harbour/include/hbdate.h
  * harbour/source/common/hbdate.c
    * changed hb_dateMilliSeconds() to return UTC julian timestamp in
      milliseconds
    * changed existing seconds, time and timestamp functions to operate
      on common OS specific functions to eliminate possible problems
      with different OS time counters
    + added new functions to operates on time and timestamp values.
      See source code for details.

  + harbour/source/rtl/cputime.c
    * moved double hb_secondsCPU( int n ) function to separate file

  * harbour/source/rtl/seconds.c
    - removed old version of date/seconds functions

  * harbour/source/vm/hashes.c
  * harbour/source/vm/arrays.c
    + added support for timestamp values as hash item indexes

  * harbour/source/vm/hashfunc.c
    + added support for find timestamp values in hash and array items
      by simple date value in AScan(), hb_HScan(), hb_AScan() and hb_RAScan()
      functions when exact comparison is not used.

  * harbour/source/vm/asort.c
    + added support for sorting timestamp values

  * harbour/source/vm/classes.c
    + added support for timestamp scallar classes
    + added support for timestamp typed instance variables

  * harbour/source/vm/memvars.c
    + added support for timestamp values in .mem files

  * harbour/source/vm/estack.c
    + show timestamp values in stack dump

  * harbour/include/hbapi.h
  * harbour/source/vm/arrays.c
    + added new C functions:
      double hb_arrayGetTD( PHB_ITEM pArray, ULONG ulIndex );
      BOOL hb_arraySetTD( PHB_ITEM pArray, ULONG ulIndex, double dTimeStamp )
      BOOL hb_arrayGetTDT( PHB_ITEM pArray, ULONG ulIndex,
                           LONG * plJulian, LONG * plMilliSec );
      BOOL hb_arraySetTDT( PHB_ITEM pArray, ULONG ulIndex,
                           LONG lJulian, LONG lMilliSec );

  * harbour/include/hbapi.h
  * harbour/source/vm/extend.c
    + accept timestamp items in date functions - use only date part of
      timestamp value
    + added new C functions:
      double hb_partd( int iParam, ... );
      BOOL hb_partdt( LONG * plJulian, LONG * plMilliSec , int iParam, ... );
      void hb_rettd( double dTimeStamp );
      void hb_rettdt( LONG lJulian, LONG lMilliSec );
      int hb_stortd( double dTimeStamp, int iParam, ... );
      int hb_stortdt( LONG lJulian, LONG lMilliSec, int iParam, ... );

  * harbour/include/hbapiitm.h
  * harbour/source/vm/itemapi.c
    + accept timestamp items in date functions - use only date part of
      timestamp value
    + added new C functions:
      char * hb_itemGetTS( PHB_ITEM pItem, char * szDateTime );
      PHB_ITEM hb_itemPutTS( PHB_ITEM pItem, const char * szDateTime );
      double hb_itemGetTD( PHB_ITEM pItem );
      PHB_ITEM hb_itemPutTD( PHB_ITEM pItem, double dTimeStamp )
      BOOL hb_itemGetTDT( PHB_ITEM pItem, LONG * plJulian, LONG * plMilliSec );
      PHB_ITEM hb_itemPutTDT( PHB_ITEM pItem, LONG lJulian, LONG lMilliSec );
    + support for timestamp items in hb_itemString(), hb_itemPadConv() and
      hb_itemTypeStr() functions

  * harbour/include/hbvm.h
  * harbour/include/hbxvm.h
  * harbour/include/hbapi.h
  * harbour/source/vm/hvm.c
    + added HB_IT_TIMESTAMP items
    * modified HB_IT_DATE internal item structure to use common structure
      with HB_IT_TIMESTAMP - it  simplifies HVM code and eliminates additional
      RT conditions.
    + added HB_IS_TIMESTAMP() and ISTIMESTAMP() macros
    + added HB_IS_DATETIME() and ISDATETIME() macros - they return true
      if item/parameter is DATE or TIMESTAMP type.
    + added void hb_vmPushTimeStamp( long lJulian, long lMilliSec );
      and xhb_vmPushTimeStamp()
    + added support for timestamp values in relational operators:
         <, <=, >, >=, =, ==
      When two timestamp values are compared then VM compares date and
      time parts in both values.
      When date and timestamp values are used in <, <=, >, >=, = operations
      then VM compares only date part in both values.
      When date and timestamp values are used in == operation then VM
      compares date part in both values and then check if time part
      of timestamp value is 0.
    + added support for timestamp values in + and - math operations.
      The following rules are used in timestamp arithmetic:
         <t> + <t> => <t>
         <t> - <t> => <n>
         <t> + <n> => <t>
         <n> + <t> => <t>
         <t> - <n> => <t>
         <d> + <t> => <t>
         <t> + <d> => <t>
         <d> - <t> => <n>
         <t> - <d> => <n>
      When number is result or argument of timestamp operation then the
      its integer part is a number of day and fractional part is the time.

  * harbour/source/rtl/dateshb.c
    + added new .prg functions to mange date and timestamp values:
      HB_DATETIME() -> <tTimeStamp>
      HB_CTOD( <cDate> [, <cDateFormat> ] ) -> <dDate>
      HB_DTOC( <dDate> [, <cDateFormat> ] ) -> <cDate>
      HB_NTOT( <nValue> ) -> <tTimeStamp>
      HB_TTON( <tTimeStamp> ) -> <nValue>
      HB_TTOC( <tTimeStamp>, [ <cDateFormat> ] [, <cTimeFormat> ] ) ->
                                                            <cTimeStamp>
      HB_CTOT( <cTimeStamp>, [ <cDateFormat> ] [, <cTimeFormat> ] ) ->
                                                            <tTimeStamp>
      HB_TTOS( <tTimeStamp> ) -> <cYYYYMMDDHHMMSSFFF>
      HB_STOT( <cDateTime> ) -> <tTimeStamp>
         <cDateTime> should be in one of the above form:
            - "YYYYMMDDHHMMSSFFF"
            - "YYYYMMDDHHMMSSFF"
            - "YYYYMMDDHHMMSSF"
            - "YYYYMMDDHHMMSS"
            - "YYYYMMDDHHMM"
            - "YYYYMMDDHH"
            - "YYYYMMDD"
            - "HHMMSSFFF"
            - "HHMMSSF"
            - "HHMMSS"
            - "HHMM"
            - "HH"
         Important is number of digits.
      HB_TSTOSTR( <tTimeStamp> ) -> <cTimeStamp> // YYYY-MM-DD HH:MM:SS.fff
      HB_STRTOTS( <cTimeStamp> ) -> <tTimeStamp>
         <cTimeStamp> should be in one of the above form:
            YYYY-MM-DD [H[H][:M[M][:S[S][.f[f[f[f]]]]]]] [PM|AM]
            YYYY-MM-DDT[H[H][:M[M][:S[S][.f[f[f[f]]]]]]] [PM|AM]
         The folowing characters can be used as date delimiters: "-", "/", "."
         T - is literal "T" - it's for XML timestamp format
         if PM or AM is used HH is in range < 1 : 12 > otherwise
         in range < 0 : 23 >
      HB_HOUR( <tTimeStamp> ) -> <nHour>
      HB_MINUTE( <tTimeStamp> ) -> <nMinute>
      HB_SEC( <tTimeStamp> ) -> <nSeconds>   // with milliseconds

  * harbour/source/rtl/datec.c
    + accept timestamp parameters in CMONTH() and CDOW() functions

  * harbour/source/rtl/empty.c
    + added support for timestamp items

  * harbour/source/rtl/itemseri.c
    + added support for timestamp items serialization

  * harbour/source/rtl/minmax.c
    + added support for timestamp values to MIN() and MAX() functions.
      when only one of given parameters is timestamp value and other
      is date value and date parts are equal then always date item
      is returned as both MIN() or MAX() value.

  * harbour/source/rtl/dates.c
    + added new C functions: hb_timeFormat(), hb_timeUnformat(),
      hb_timeStampFormat(), hb_timeStampUnformat()

  * harbour/source/rtl/valtype.c
    + added .prg functions: HB_ISDATETIME(), HB_ISTIMESTAMP()

  * harbour/source/rtl/transfrm.c
    + added support for timestamp items formatting.
    + added new function modifier @T.
      When @T is used without @D then only time part of timestamp value
      is formatted and return.
      When @D is used without @T then only date part of timestamp value
      is formatted and return.

  * harbour/source/rtl/tbrowse.prg
    + display timestamp values

  * harbour/source/rtl/philes.c
    + accept timestamp value as second parameter of HB_FSETDATETIME()
      function
    + store file data and time in second parameter of HB_FGETDATETIME()
      as timestamp value.
    Old parameters (2-dDate, 3-cTime) are still supported but please think
    about removing them - they are redundant.

  * harbour/source/rtl/filesys.c
    * updated function names


  * harbour/source/rdd/dbf1.c
    + added native support for time and timestamp fields

  * harbour/include/hbrddcdx.h
  * harbour/include/hbrddnsx.h
  * harbour/source/rdd/dbfntx/dbfntx1.c
  * harbour/source/rdd/dbfcdx/dbfcdx1.c
  * harbour/source/rdd/dbfnsx/dbfnsx1.c
  * harbour/source/rdd/dbffpt/dbffpt1.c
    + added support for indexing timestamp fields
    + added support for using DATE values with timestamp fields
      which replicate HVM behavior.
      SEEK and SEEKLAST with date value when active index is on
      timestamp positions to 1-st or last record where date part
      of indexed timesamp value is equal.
      Settings scopes to date values when active index is on timestamp
      value reduce the visible record range to these ones which have
      date part of timestamp value in the range of dates values used
      for scopes. It possible to mix date and timestamp values in scope
      and set one scope to date value and the second to timesamp.

  * harbour/source/rdd/sdf1.c
  * harbour/source/rdd/delim1.c
    + added support for exporting timestamp fields

  * harbour/source/rdd/dbsql.c
    ! fixed typo in logical value export
    + export timestamp fields.
      Please update the format to given SQL syntax.


  * harbour/contrib/hbct/files.c
    + changed SETFDATI() to optionally accept timestamp parameter
      instead of two parameters dDate and cTime

  * harbour/contrib/hbct/misc1.c
    + added timestamp support to XTOC() function

  * harbour/contrib/hbct/misc2.c
    + added timestamp support to COMPLEMENT() function

  * harbour/contrib/hbct/dattime2.c
    + accept timestamp values in ADDMONTH(), DOY(), ISLEAP(), QUARTER()
      LASTDAYOM(), WEEK() functions

  * harbour/contrib/hbmzip/hbmzip.c
    + updated HB_ZipFileCreate( hZip, cZipName, tDateTime, cTime, ... )
      functions to optionaly accept timestamp value in 3-rd parameter
      instead od dDate, and cTime in 3-rd and 4-th parameters.
    + updated HB_UnzipFileInfo( hUnzip, @cZipName, @tDateTime, @cTime, ... )
      to return timestamp value in 3-rd parameter instead of date value.
      TODO: Please think about removing 4-th parameter from:
               HB_ZipFileCreate( hZip, cZipName, tDateTime, cTime, ... )
               HB_UnzipFileInfo( hUnzip, @cZipName, @tDateTime, @cTime, ... )
            Now it's redundant.
  * harbour/contrib/hbmzip/readme.txt
    * updated parameters description for above functions

  * harbour/contrib/hbnf/descendn.c
    + added timestamp support to FT_DESCEND() function

  * harbour/contrib/hbclipsm/date.c
    + accept timestamp values in DATEASAGE(), DATEASARRAY() and DATEISLEAP()
      functions

  * harbour/contrib/hbmisc/dates2.c
    + accept timestamp values in ISLEAPYEAR(), DAYSINMONTH(), EOM(), BOM(),
      WOM(), WOY(), EOY() and BOY() functions


   The following contrib files should be updated but I'm leaving it to
   other developers who want to keep this code alive:
         contrib/hbtip/utils.c
         contrib/hbvpdf/hbvpdf.prg
         contrib/hbvpdf/hbvpdft.prg
         contrib/hbwin/win_dll.c
            some minor cleanups if necessary and authors will find
            timestamp values usable

         contrib/hbole/ole2.c
         contrib/hbwin/win_ole.c
            add support for timestamp values in OLE

         contrib/rddado/adordd.prg
         contrib/rddads/ads1.c
         contrib/rddads/adsx.c
         contrib/rddsql/...
            add support for timestamp values in RDDs

   Warning: this implementation is not xHarbour compatible. There are many
   important differences. Mostly on C level and used API. Please be careful
   in porting xHarbour source code to Harbour.
2009-03-21 15:04:43 +00:00

258 lines
18 KiB
C

/*
* $Id$
*/
/*
* Harbour Project source code:
* Header file for the PCODE declarations
*
* Copyright 1999 Antonio Linares <alinares@fivetech.com>
* www - http://www.harbour-project.org
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option)
* any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this software; see the file COPYING. If not, write to
* the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
* Boston, MA 02111-1307 USA (or visit the web site http://www.gnu.org/).
*
* As a special exception, the Harbour Project gives permission for
* additional uses of the text contained in its release of Harbour.
*
* The exception is that, if you link the Harbour libraries with other
* files to produce an executable, this does not by itself cause the
* resulting executable to be covered by the GNU General Public License.
* Your use of that executable is in no way restricted on account of
* linking the Harbour library code into it.
*
* This exception does not however invalidate any other reasons why
* the executable file might be covered by the GNU General Public License.
*
* This exception applies only to the code released by the Harbour
* Project under the name Harbour. If you copy code from other
* Harbour Project or Free Software Foundation releases into a copy of
* Harbour, as the General Public License permits, the exception does
* not apply to the code that you add in this way. To avoid misleading
* anyone as to the status of such modified files, you must delete
* this exception notice from them.
*
* If you write modifications of your own for Harbour, it is your choice
* whether to permit this exception to apply to your modifications.
* If you do not wish that, delete this exception notice.
*
*/
#ifndef HB_PCODE_H_
#define HB_PCODE_H_
/* NOTE:
*
* IMPORTANT:
* Always add new pcodes to the end of the list to maintain compatibility.
*
*/
/* NOTE:
* Please update any opcode lookup tables present in
* genc.c
* harbour.c
* when new opcode is added
*/
typedef enum
{
HB_P_AND, /* 0 performs the logical AND of two latest stack values, removes them and places result */
HB_P_ARRAYPUSH, /* 1 places on the virtual machine stack an array element */
HB_P_ARRAYPOP, /* 2 pops a value from the eval stack into an array element */
HB_P_ARRAYDIM, /* 3 instructs the virtual machine to build an array with some specific dimensions */
HB_P_ARRAYGEN, /* 4 instructs the virtual machine to build an array and load element from the stack */
HB_P_EQUAL, /* 5 check if the latest two values on the stack are equal, removing them and leaving the result */
HB_P_ENDBLOCK, /* 6 end of a codeblock definition */
HB_P_ENDPROC, /* 7 instructs the virtual machine to end execution */
HB_P_EXACTLYEQUAL, /* 8 check if the latest two values on the stack are exactly equal, removing them and leaving the result */
HB_P_FALSE, /* 9 pushes false on the virtual machine stack */
HB_P_FORTEST, /* 10 For STEP. If step > 1 less. If step < 1 greater. */
HB_P_FUNCTION, /* 11 instructs the virtual machine to execute a function saving its result */
HB_P_FUNCTIONSHORT, /* 12 instructs the virtual machine to execute a function saving its result */
HB_P_FRAME, /* 13 instructs the virtual machine about how many parameters and locals a function uses */
HB_P_FUNCPTR, /* 14 returns a function address pointer */
HB_P_GREATER, /* 15 checks if the second latest value on the stack is greater that the lastest one */
HB_P_GREATEREQUAL, /* 16 checks if the second latest value on the stack is greater equal that the latest one, leaves the result only */
HB_P_DEC, /* 17 decrements the latest value on the virtual machine stack */
HB_P_DIVIDE, /* 18 divides the latest two values on the stack, removing them and leaving the result */
HB_P_DO, /* 19 instructs the virtual machine to execute a function discarding its result */
HB_P_DOSHORT, /* 20 instructs the virtual machine to execute a function discarding its result */
HB_P_DUPLICATE, /* 21 places a copy of the latest virtual machine stack value on to the stack */
HB_P_PUSHTIMESTAMP, /* 22 places a timestamp constant value on the virtual machine stack */
HB_P_INC, /* 23 increments the latest value on the virtual machine stack */
HB_P_INSTRING, /* 24 checks if the second latest value on the stack is a substring of the latest one */
HB_P_JUMPNEAR, /* 25 jumps to a relative offset 1 Byte */
HB_P_JUMP, /* 26 jumps to a relative offset 2 Bytes */
HB_P_JUMPFAR, /* 27 jumps to a relative offset 3 Bytes */
HB_P_JUMPFALSENEAR, /* 28 checks a logic expression of the stack and jumps to a relative offset */
HB_P_JUMPFALSE, /* 29 checks a logic expression of the stack and jumps to a relative offset */
HB_P_JUMPFALSEFAR, /* 30 checks a logic expression of the stack and jumps to a relative offset */
HB_P_JUMPTRUENEAR, /* 31 checks a logic expression of the stack and jumps to a relative offset */
HB_P_JUMPTRUE, /* 32 checks a logic expression of the stack and jumps to a relative offset */
HB_P_JUMPTRUEFAR, /* 33 checks a logic expression of the stack and jumps to a relative offset */
HB_P_LESSEQUAL, /* 34 checks if the second latest value on the stack is less equal that the latest one, leaves the result only */
HB_P_LESS, /* 35 checks if the second latest value on the stack is less that the lastest one */
HB_P_LINE, /* 36 currently compiled source code line number */
HB_P_LOCALNAME, /* 37 sets the name of local variable */
HB_P_MACROPOP, /* 38 compile and run - pop a value from the stack */
HB_P_MACROPOPALIASED, /* 39 compile and run - pop a field value from the stack */
HB_P_MACROPUSH, /* 40 compile and run - leave the result on the stack */
HB_P_MACROARRAYGEN, /* 41 generate array from arguments set(s) on HVM stack { &var } */
HB_P_MACROPUSHLIST, /* 42 compile and run - leave the result on the stack */
HB_P_MACROPUSHINDEX, /* 43 push array items using macro array index */
HB_P_MACROPUSHPARE, /* 44 compile and run - leave the result on the stack */
HB_P_MACROPUSHALIASED, /* 45 compile and run - leave the field value on the stack */
HB_P_MACROSYMBOL, /* 46 compile into a symbol name (used in function calls) */
HB_P_MACROTEXT, /* 47 macro text substitution */
HB_P_MESSAGE, /* 48 sends a message to an object */
HB_P_MINUS, /* 49 subs the latest two values on the stack, removing them and leaving the result */
HB_P_MODULUS, /* 50 calculates the modulus of the two values on the stack, removing them and leaving the result */
HB_P_MODULENAME, /* 51 sets the name of debugged module */
/* start: pcodes generated by the macro compiler - the symbol address is used */
HB_P_MMESSAGE, /* 52 */
HB_P_MPOPALIASEDFIELD, /* 53 */
HB_P_MPOPALIASEDVAR, /* 54 */
HB_P_MPOPFIELD, /* 55 */
HB_P_MPOPMEMVAR, /* 56 */
HB_P_MPUSHALIASEDFIELD, /* 57 */
HB_P_MPUSHALIASEDVAR, /* 58 */
HB_P_MPUSHBLOCK, /* 59 */
HB_P_MPUSHFIELD, /* 60 */
HB_P_MPUSHMEMVAR, /* 61 */
HB_P_MPUSHMEMVARREF, /* 62 */
HB_P_MPUSHSYM, /* 63 */
HB_P_MPUSHVARIABLE, /* 64 */
/* end: */
HB_P_MULT, /* 65 multiplies the latest two values on the stack, removing them and leaving the result */
HB_P_NEGATE, /* 66 numerically negates the latest value on the stack */
HB_P_NOOP, /* 67 no operation */
HB_P_NOT, /* 68 logically negates the latest value on the stack */
HB_P_NOTEQUAL, /* 69 checks if the latest two stack values are equal, leaves just the result */
HB_P_OR, /* 70 performs the logical OR of two latest stack values, removes them and places result */
HB_P_PARAMETER, /* 71 creates PRIVATE variables and assigns values to functions paramaters */
HB_P_PLUS, /* 72 adds the latest two values on the stack, removing them and leaving the result */
HB_P_POP, /* 73 removes the latest value from the stack */
HB_P_POPALIAS, /* 74 pops the item from the eval stack and selects the current workarea */
HB_P_POPALIASEDFIELD, /* 75 pops aliased field */
HB_P_POPALIASEDFIELDNEAR, /* 76 pops aliased field */
HB_P_POPALIASEDVAR, /* 77 pops aliased variable (either a field or a memvar) */
HB_P_POPFIELD, /* 78 pops unaliased field */
HB_P_POPLOCAL, /* 79 pops the contents of the virtual machine stack onto a local variable */
HB_P_POPLOCALNEAR, /* 80 pops the contents of the virtual machine stack onto a local variable */
HB_P_POPMEMVAR, /* 81 pops the contents of a memvar variable to the virtual machine stack */
HB_P_POPSTATIC, /* 82 pops the contents of the virtual machine stack onto a static variable */
HB_P_POPVARIABLE, /* 83 pops the contents of an undeclared variable from the virtual machine stack */
HB_P_POWER, /* 84 calculates the power of the two values on the stack, removing them and leaving the result */
HB_P_PUSHALIAS, /* 85 saves the current workarea number on the eval stack */
HB_P_PUSHALIASEDFIELD, /* 86 pushes aliased field */
HB_P_PUSHALIASEDFIELDNEAR, /* 87 pushes aliased field */
HB_P_PUSHALIASEDVAR, /* 88 pushes aliased variable (either a field or a memvar) */
HB_P_PUSHBLOCK, /* 89 start of a codeblock definition */
HB_P_PUSHBLOCKSHORT, /* 90 start of a codeblock definition */
HB_P_PUSHFIELD, /* 91 pushes an unaliased field */
HB_P_PUSHBYTE, /* 92 places a 1 byte integer number on the virtual machine stack */
HB_P_PUSHINT, /* 93 places an integer number on the virtual machine stack */
HB_P_PUSHLOCAL, /* 94 pushes the contents of a local variable to the virtual machine stack */
HB_P_PUSHLOCALNEAR, /* 95 pushes the contents of a local variable to the virtual machine stack */
HB_P_PUSHLOCALREF, /* 96 pushes a local variable by reference to the virtual machine stack */
HB_P_PUSHLONG, /* 97 places an integer number on the virtual machine stack */
HB_P_PUSHMEMVAR, /* 98 pushes the contents of a memvar variable to the virtual machine stack */
HB_P_PUSHMEMVARREF, /* 99 pushes the a memvar variable by reference to the virtual machine stack */
HB_P_PUSHNIL, /* 100 places a nil on the virtual machine stack */
HB_P_PUSHDOUBLE, /* 101 places a double number on the virtual machine stack */
HB_P_PUSHSELF, /* 102 pushes Self for the current processed method */
HB_P_PUSHSTATIC, /* 103 pushes the contents of a static variable to the virtual machine stack */
HB_P_PUSHSTATICREF, /* 104 pushes the a static variable by reference to the virtual machine stack */
HB_P_PUSHSTR, /* 105 places a string on the virtual machine stack */
HB_P_PUSHSTRSHORT, /* 106 places a string on the virtual machine stack */
HB_P_PUSHSYM, /* 107 places a symbol on the virtual machine stack */
HB_P_PUSHSYMNEAR, /* 108 places a symbol on the virtual machine stack */
HB_P_PUSHVARIABLE, /* 109 pushes the contents of an undeclared variable to the virtual machine stack */
HB_P_RETVALUE, /* 110 instructs the virtual machine to return the latest stack value */
HB_P_SEND, /* 111 send operator */
HB_P_SENDSHORT, /* 112 send operator */
HB_P_SEQBEGIN, /* 113 BEGIN SEQUENCE */
HB_P_SEQEND, /* 114 END SEQUENCE */
HB_P_SEQRECOVER, /* 115 RECOVER statement */
HB_P_SFRAME, /* 116 sets the statics frame for a function */
HB_P_STATICS, /* 117 defines the number of statics variables for a PRG */
HB_P_STATICNAME, /* 118 sets the name of static variable */
HB_P_SWAPALIAS, /* 119 restores the current workarea number from the eval stack */
HB_P_TRUE, /* 120 pushes true on the virtual machine stack */
HB_P_ZERO, /* 121 places a ZERO on the virtual machine stack */
HB_P_ONE, /* 122 places a ONE on the virtual machine stack */
HB_P_MACROFUNC, /* 123 execute a function saving its result */
HB_P_MACRODO, /* 124 execute a function discarding its result */
HB_P_MPUSHSTR, /* 125 Macro compiled pushed string */
HB_P_LOCALNEARADDINT, /* 126 Add/Subtract specified int into specified local without using the stack. */
HB_P_MACROPUSHREF, /* 127 Reference to macro variable @&mvar */
HB_P_PUSHLONGLONG, /* 128 places an integer number on the virtual machine stack */
HB_P_ENUMSTART, /* 129 Start of FOR EACH loop */
HB_P_ENUMNEXT, /* 130 Next item of FOR EACH loop */
HB_P_ENUMPREV, /* 131 Previous item of FOR EACH loop */
HB_P_ENUMEND, /* 132 End of FOR EACH loop */
HB_P_SWITCH, /* 133 SWITCH using long values */
HB_P_PUSHDATE, /* 134 places a data constant value on the virtual machine stack */
/* optimalization of inlined math operations */
HB_P_PLUSEQPOP, /* 135 adds a value to the variable reference */
HB_P_MINUSEQPOP, /* 136 subs a value from the variable reference */
HB_P_MULTEQPOP, /* 137 multiplies a variable reference by a value */
HB_P_DIVEQPOP, /* 138 divides the var reference by a value */
HB_P_PLUSEQ, /* 139 adds a value to the variable reference, leave result on the stack */
HB_P_MINUSEQ, /* 140 subs a value from the variable reference, leave result on the stack */
HB_P_MULTEQ, /* 141 multiplies a variable reference by a value, leave result on the stack */
HB_P_DIVEQ, /* 142 divides the var reference by a value, leave result on the stack */
HB_P_WITHOBJECTSTART, /* 143 start WITH OBJECT code */
HB_P_WITHOBJECTMESSAGE, /* 144 push message for WITH OBJECT */
HB_P_WITHOBJECTEND, /* 145 end WITH OBJECT code */
HB_P_MACROSEND, /* 146 send operator with macrlist params */
HB_P_PUSHOVARREF, /* 147 pushes reference to object variable */
HB_P_ARRAYPUSHREF, /* 148 pushes reference to array element */
HB_P_VFRAME, /* 149 frame with variable number of parameters */
HB_P_LARGEFRAME, /* 150 frame with more then 255 locals */
HB_P_LARGEVFRAME, /* 151 frame with variable number of parameters and more then 255 locals */
HB_P_PUSHSTRHIDDEN, /* 152 places a "hidden" string on the virtual machine stack */
HB_P_LOCALADDINT, /* 153 Add/Subtract specified int into specified local without using the stack. */
HB_P_MODEQPOP, /* 154 calculates the modulus of var reference and a value */
HB_P_EXPEQPOP, /* 155 calculates the power of var reference and a value */
HB_P_MODEQ, /* 156 calculates the modulus of var reference and a value, leave result on the stack */
HB_P_EXPEQ, /* 157 calculates the power of var reference and a value, leave result on the stack */
HB_P_DUPLUNREF, /* 158 places a copy of the latest virtual machine stack value on to the stack and unreference the source one */
HB_P_MPUSHBLOCKLARGE, /* 159 code block generated by the macro compiler larger then 64kb */
HB_P_MPUSHSTRLARGE, /* 160 Macro compiled pushed string */
HB_P_PUSHBLOCKLARGE, /* 161 start of a codeblock definition */
HB_P_PUSHSTRLARGE, /* 162 places a string on the virtual machine stack */
HB_P_SWAP, /* 163 swap n+1 times two items starting from the most top one on the virtual machine stack */
HB_P_PUSHVPARAMS, /* 164 push variable function/method parameters on HVM stack */
HB_P_PUSHUNREF, /* 165 push unreferenced top item on HVM stack */
HB_P_SEQALWAYS, /* 166 set BEGIN SEQUENCE/ALWAYS section */
HB_P_ALWAYSBEGIN, /* 167 start ALWAYS section */
HB_P_ALWAYSEND, /* 168 finish ALWAYS section */
HB_P_DECEQPOP, /* 169 decrements the var reference */
HB_P_INCEQPOP, /* 170 increments the var reference */
HB_P_DECEQ, /* 171 decrements the var reference, leave result on the stack */
HB_P_INCEQ, /* 172 increments the var reference, leave result on the stack */
HB_P_LOCALDEC, /* 173 decrements the local variable */
HB_P_LOCALINC, /* 174 increments the local variable */
HB_P_LOCALINCPUSH, /* 175 increments the local variable, push result on the stack */
HB_P_PUSHFUNCSYM, /* 176 places a symbol on the virtual machine stack */
HB_P_HASHGEN, /* 177 instructs the virtual machine to build a hash and load element from the stack */
HB_P_SEQBLOCK, /* 178 set BEQIN SEQUENCE WITH block */
HB_P_THREADSTATICS, /* 179 mark thread static variables */
HB_P_LAST_PCODE /* 180 this defines the number of defined pcodes */
} HB_PCODE;
#endif /* HB_PCODE_H_ */