Commit Graph

45 Commits

Author SHA1 Message Date
David G. Holm
19b6db6f49 See ChangeLog entry 2000-08-08 17:15 UTC-0400 David G. Holm <dholm@jsd-llc.com> 2000-08-08 21:19:35 +00:00
Ron Pinkas
e09d364512 2000-07-31 09:00 UTC+0800 Ron Pinkas <ron@profit-master.com>
* source/compiler/simplex.c
   * source/macro/macro.slx
     ! Corrected compiler warnings

   * tests/testwarn.prg
   * utils/hbdoc/ft_funcs.prg
     * Commented AS USUAL until votes results tabulated
2000-07-31 15:58:41 +00:00
Viktor Szakats
2f43451c9d 2000-07-30 14:32 UTC+0100 Victor Szakats <info@szelvesz.hu> 2000-07-30 12:44:49 +00:00
Ron Pinkas
6f4ad44c3a Corrected testwarn.prg to not have missing externals. 2000-07-26 00:25:57 +00:00
Ron Pinkas
b3e611d907 2000-07-14 22:40 UTC+0800 Ron Pinkas <ron@profit-master.com>
* source/compiler/harbour.slx
     ! Removed Todo: Hex Numbers. There are no more known TODOs.
2000-07-15 05:42:12 +00:00
Ron Pinkas
7fdc515e94 2000-07-14 09:40 UTC+0800 Ron Pinkas <ron@profit-master.com>
* source/compiler/simplex.c
     ! Minor correction, to accept a match, if all rule's tokens used.
2000-07-14 16:42:37 +00:00
Maurilio Longo
3e886ea141 20000529-00:01 GMT+2 Maurilio Longo <maurilio.longo@libero.it> 2000-05-28 22:02:50 +00:00
Viktor Szakats
be81ee127d 2000-05-27 23:12 UTC+0100 Victor Szakats <info@szelvesz.hu> 2000-05-28 19:52:03 +00:00
Ron Pinkas
e6afd45d90 20000522-09:40 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* contrib/hbclip.ch
     ! Updated to reflect latest sysntax.

   * tests/testwarn.ch
     ! Updated translate segment to reflect latest sysntax.
2000-05-22 17:28:03 +00:00
Ron Pinkas
eb2d8afdb4 20000522-06:15 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.l
     + Added "as structure", "as stru", "as array of structure", "as array of stru"

   * source/compiler/hbpcode.c
     * Improved some logic in hb_StrongType()

   * source/vm/hvm.c
     ! Corrected startup symbol when having to use Main() as per Ryszard.

   * source/pp/pptable.c
     + Added the equivalent of:
        #COMMANDS STRUCTURE <StruName> <Var1> AS <Type1> [, <VarN> AS <TypeN> ] => ;
                  STATIC __<StruName> := {|| IF( __<StruName> == NIL, , ) , HB_Structure( <"StruName">, { <"Var1"> [, <"VarN">] } )} ;;
                  DECLARE <StruName> <Var1> AS <Type1> [ <VarN> AS <TypeN> ] ;;
                  #TRANSLATE AS NEW <ClassName> => AS CLASS <StruName> := ( Eval( __<StruName> ), HB_Structure( <StruName> ) )

	#TRANSLATE AS NEW <ClassName> => AS CLASS <ClassName> := <ClassName>():New()

   * source/rtl/tclass.prg
     + Added Function HB_Structure() ( Fully Declared! ) This function is used internally, but may be freely called from Clipper level.
       It Aceepts Parameter 1 Structure Name, and optional parameter 2, as array of structure variable names.
       If called with 2nd parameter, returns NIL (just creates the new Structure), if called with just parameter 1, it returns
       new instance of defined structure.

   + tests\teststru.prg
     + Added demo for new structure syntax
2000-05-22 13:53:14 +00:00
Ron Pinkas
a2b2b0ab65 20000521-14:42 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* tests/testwarn.prg
     ! Consolidate #translate rules, and verified that it can compile under Clipper
2000-05-21 21:43:25 +00:00
Ron Pinkas
c7e237273e 20000521-14:15 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.l
     + Added "as class"

   * source/compiler/harbour.y
     ! Fixed shift conflicts and reduce conflicts.
     * Modified rules for syntax "AS Object ClassName" to "As Class ClassName"

   * tests/testwarn.prg
     ! Corrected the #translate to reflect latest syntax
     ! Corrected syntax to use AS CLASS ClassName instead of AS OBJECT ClassName.
2000-05-21 21:19:51 +00:00
Ron Pinkas
8e184f78a4 20000520-21:30 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* include/hbvmpub.h
     + Added: #define HB_FS_FIRST    ( ( HB_SYMBOLSCOPE ) 0x40 )

   * source/compiler/genc.c
     + Added logic to add | HB_FS_FIRST to first defined symbol in a prg.

   * source/vm/hvm.c
     * Modified hb_vmProcessSymbols() to llok for HB_FS_FIRST for startup procedure instead of any first symbol.

   * source/compiler/harbour.y
     * Minor consilidation in AsType
       *** I am aware of 6 reduce conflicts resulting from previous removal of FROM_CLASS, and am looking into it. ***

   * tests/testwarn.prg
     ! Corrected the #translate to reflect latest syntax
2000-05-21 04:55:06 +00:00
Ron Pinkas
9339186a1b 20000519-15:40 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/hbpcode.c
     + Minor correction in hb_compStrongType()
2000-05-19 22:41:06 +00:00
Ron Pinkas
59501e617d 20000519-02:05 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* include/hbcomp.h
     ! Consoldated COMDECLARED and COMMETHOD into COMDECLARED
     + Added member pClass to COMDECLARED
     + Added member pLast to COMCLASS

   * source/compiler/harbour.y
     + Added support for Methods/Datas of type Object of a declared Class.

   * source/compiler/harbour.c
     ! Fixed bug in hb_compMethodAdd()

   * source/compiler/hbpcode.c
     + Added Strong Type Checking to Objects syntax.

   * include/hberrors.h
     + Added : "HB_COMP_WARN_MESSAGE_NOT_FOUND"

   * source/compiler/hbgenerr.c
     + Added : "3Message \'%s\' not known in Class \'%s\'"

   * tests/testwarn.prg
     + Added code to demonstrate syntax and warnings for OO Strong Type Checking.
2000-05-19 09:25:06 +00:00
Ron Pinkas
4eb57576a2 20000514-22:25 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.l
    - Removed: not needed states
    - Removed "class method" "class data"
    + Added rules for "declare""

  * source/compiler/harbour.y
    * Changed rules for DECLARE FUNCTION as per Ryszard suhhestion, New Sysntax is simply:
        DECLARE FunName([...]) [As ...]
    * Changed rules for DECLARE CLASS as per Ryszard suhhestion, New Sysntax is simply:
        DECLARE ClassName MethodName([...]) [As ...] DataVar [As ...]

  * source/compiler/harbour.c
    ! Minor correction to allow final declaration to override previous declaration of same function.

  * tests/testwarn.prg
    * Modified code to demonstrate syntax functions, classes and objects of a declared class declarations.
2000-05-15 05:35:04 +00:00
Ron Pinkas
998c3e4c84 20000514-12:20 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.y
    + Seperated the DECLARE... from Function, moved into a Declare, and Added Declare as type of Source.
    ! Added reset of hb_comp_iVarScope to DECLARE... to fix wrong "Statement not allowed outside of procedure or function"
2000-05-15 01:59:21 +00:00
Ron Pinkas
cd9e54dc06 20000514-12:20 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.y
    + Seperated the DECLARE... from Function, moved into a Declare, and Added Declare as type of Source.
    ! Added reset of hb_comp_iVarScope to DECLARE... to fix wrong "Statement not allowed outside of procedure or function"


   * source/compiler/hbgenerr.c
     * Modified : "3Duplicate Declaration of %s \'%s\'" to accept 1st parameter type of redeclaration ( Function, Class, Method ).

   * source/compiler/harbour.c
     * Modified calls to hb_compGenWarning() to use additional parameter of redclaration type.
2000-05-14 19:22:22 +00:00
Ron Pinkas
7943176b91 20000514-10:07 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.l
    ! Fixed parse error when DO OPTIONAL WITH 1 or " or other non alpha charcaters
    ! Fixed parse error when FOR Var := OPTIONAL TO ...
2000-05-14 17:07:30 +00:00
Ron Pinkas
d1d3198841 20000514-09:10 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.l
    ! Fixed parse error when DO OPTIONAL WITH ...
    * Changed FROM to FROM CLASS in AS Obect FROM CLASS ... (fixed conflict of FROM with DO FROM ...)
    * Changed AS ... ARRAY to AS ARRAY OF ...
2000-05-14 16:12:23 +00:00
Ron Pinkas
95dd157b13 20000512-08:00 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.y
    + Added support for END to be used with FOR loops.
2000-05-12 15:07:48 +00:00
Ron Pinkas
30cc98a20d 20000510-03:00 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* include/hbcomp.h
    + Added new structures COMCLASS and COMMETHOD
    + Added new element pClass to structure VAR
    + Added:
	extern PCOMCLASS hb_compClassAdd( char * );
	extern PCOMCLASS hb_compClassFind( char * );
	extern PCOMMETHOD hb_compMethodAdd( PCOMCLASS pClass, char * );
	extern PCOMMETHOD hb_compMethodFind( PCOMCLASS pClass, char * );

  * source/compiler/harbour.c
    + Added:
	PCOMCLASS hb_compClassAdd( char * );
	PCOMCLASS hb_compClassFind( char * );
	PCOMMETHOD hb_compMethodAdd( PCOMCLASS pClass, char * );
	PCOMMETHOD hb_compMethodFind( PCOMCLASS pClass, char * );
    * Modified hb_compVariableAdd() to process params of declared class methods.

  * source/compiler/harbour.l
    + Added tokens CLASSMETHOD CLASSDATA and FROMCLASS

  * source/compiler/harbour.y
    + Added support for class declaration syntax:
      DECLARE CLASS ClassName HAS Method MethodName( ... ) As ... HAS Data PropertyName ...
    + Added support for declaration of Object of a sdeclared class sysntax:
      DECLARE oObjectVar AS Object FROM ClassName

  * source/compiler/hbpcode.c
    + Started support for object methods and properties type checking.

  * tests/testwarn.prg
    + Added code to demonstrate declarion of classes and objects of a declared class.
2000-05-10 10:13:16 +00:00
Ron Pinkas
d3cba77156 20000508-22:50 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.l
     - Removed un used token DECLARE_

   * source/compiler/harbour.y
     ! Fixed warning about conflict
     ! Verified all calls to hb_compVariableAdd() to use hb_comp_cVarType (and VT_OFFSET_* constants) as 2nd parameter
     + Added rules to support syntax of declartion of variable by reference parameter.

   * include/hbcomp.h
     + Added :
	#define VT_OFFSET_BYREF             60
	#define VT_OFFSET_VARIANT           90
	#define VT_OFFSET_OPTIONAL          90

   * source/compiler/harbour.c
     * Minor cleanup in hb_compVariableAdd()

   * source/compiler/hbpcode.c
     * Modified hb_compStrongType() to use VT_OFFSET_* constants.

   * source/compiler/hbgenerr.c
     * Changed "number" to "#" in HB_COMP_WARN_PARAM_TYPE message.

   * tests/testwarn.prg
     + Added code to demonstrate new "Declared Refernced Paramater" syntax:
         DECLARE FRead( nHandle As Num, @cBufferVar As Char, nBytes As Num ) AS Num
2000-05-09 06:08:45 +00:00
Ron Pinkas
0d504bfd5c 20000507-21:20 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.l
     + Added token "optional"

   * source/compiler/harbour.y
     + Added token "optional", DecParam, DecParamList, OptParams.
     + Added support for optional parameters syntax in declared functions.

   * source/compiler/harbour.c
     + Added logic in hb_compVariableAdd() to deal with optional parameters of declared functions.

   * source/compiler/hbpcode.c
     + Added logic in hb_compStrongType() to deal with optional parameters of declared functions.

   * tests/testwarn.prg
     + Added code to demonstrate usage and warnings of optional parameters in declared functions.
2000-05-08 04:28:21 +00:00
Ron Pinkas
8d68c4da51 20000507-13:35 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* include/hberrors.h
     + Added : #define HB_COMP_WARN_VAL_NOT_USED               20

   * source/compiler/harbour.c
     + Added logic to hb_compOptimizeFrames() to warn about invalid statics usage.

   * source/compiler/hbgenerr.c
     + Added: "3Value of Variable \'%s\' never used"

   * source/compiler/hbpcode.c
     * Enhanced support for statics

   * tests/testwarn.prg
     + Added more code to demonstrate more warnings.
2000-05-07 20:36:33 +00:00
Ron Pinkas
3e7718e76e 20000507-05:20 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* include/hbpcomp.c
     + Added pPrivates to structure FUNCTION.

   * source/compiler/harbour.c
     + Added logic to maintain linked list pPrivates of pFunc.

   * source/compiler/harbour.y
     + Added support for MEMVAR AS ... syntax.

   * source/compiler/hbpcode.c
     + Added support for FIELD AS ... and MEMVAR AS both local and global.
     ! More refinments

   * tests/testwarn.prg
     + Added code to demonstrate "Adaptive Type Checking".
2000-05-07 12:27:18 +00:00
Ron Pinkas
2583f6096d 20000504-22:40 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.c
     - Removed static qualifier from hb_compVariableGetPos() so it can be called from hb_compStrongType()

   * source/compiler/hbpcode.c
     + Added logic to hb_compStrongType() to allow assigment of NIL to any type variable.
     + Added "Adaptive Type Checking" to control type mismatch in undeclared variables.

   * include/hberrors.h
     ! Added #define HB_COMP_ARRAY_ASSIGN_TYPE to HB_COMP_WARN_ARRAY_ASSIGN_TYPE

   * source/compiler/hbgenerr.c
     * Added : Moved "Suspecious ..." to level w4

   * tests/testwarn.prg
     + Added code to demonstrate "Adaptive Type Checking".
2000-05-05 05:43:21 +00:00
Ron Pinkas
7b648ebc7e 20000504-04:05 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/hbpcode.c
     ! Fixed GPF when Array of 0 elements created.
2000-05-04 11:05:09 +00:00
Ron Pinkas
86e2384686 20000504-03:10 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.l
     + Added:
	"as bool array"      { return AS_LOGICAL_ARRAY; }
	"as boolean array"   { return AS_LOGICAL_ARRAY; }
	"as var"             { return AS_VARIANT; }
	"as variant"         { return AS_VARIANT; }
	"as num array"       { return AS_NUMERIC_ARRAY; }
	"as numeric array"   { return AS_NUMERIC_ARRAY; }
	"as char array"      { return AS_CHARACTER_ARRAY; }
	"as character array" { return AS_CHARACTER_ARRAY; }
	"as string array"    { return AS_CHARACTER_ARRAY; }
	"as logical array"   { return AS_LOGICAL_ARRAY; }
	"as bool array"      { return AS_LOGICAL_ARRAY; }
	"as boolean array"   { return AS_LOGICAL_ARRAY; }
	"as date array"      { return AS_DATE_ARRAY; }
	"as array array"     { return AS_ARRAY_ARRAY; }
	"as block array"     { return AS_BLOCK_ARRAY; }
	"as object array"    { return AS_OBJECT_ARRAY; }
	"as var array"       { return AS_VARIANT; }
	"as variant array"   { return AS_VARIANT; }

   * source/compiler/harbour.y
     + Added AsArray
     + Added : %token AS_NUMERIC_ARRAY AS_CHARACTER_ARRAY AS_LOGICAL_ARRAY AS_DATE_ARRAY AS_ARRAY_ARRAY AS_BLOCK_ARRAY AS_OBJECT_ARRAY AS_VARIANT_ARRAY
     + Added rules to support declarion of array elements type

   * source/compiler/harbour.c
     ! Minor fix to hb_compVariableGetPos() to signify var usage if warning level lower than 3

   * source/compiler/hbpcode.c
     + Added logic to hb_compStrongType() to support type checking of array elements declared type.

   * include/hberrors.h
     + Added #define HB_COMP_ARRAY_ASSIGN_TYPE

   * source/compiler/hbgenerr.c
     + Added : "3Incompatible type in assignment to declared array element expected: \'%s\'"

   * tests/testwarn.prg
     + Added code to demonstrate more warnings.

   * contrib/hbclip/hbclip.ch
     + Added additional strong typing compatibility translations
2000-05-04 10:26:57 +00:00
Ron Pinkas
eec5c93ec1 20000503-21:30 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* include/hbcomp.h
     + Added:
	#define VU_NOT_USED    0
	#define VU_INITIALIZED 1
	#define VU_USED        2

   * source/compiler/harbour.c
      * Modified refrences to pVar->iUsed to use new VU_* constants.

   * source/compiler/hbpcode.c
     * Enhanced hb_compStrongType() to check and set pVar->iUsed with new VU_*constants.
2000-05-04 04:35:54 +00:00
Ron Pinkas
7da8b5fc2a 20000503-01:45 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* include/hberrors.h
     + Added:
        #define HB_COMP_NOT_INITIALIZED

   * source/compiler/hbgenerr.c
     + Added: "3Variable \'%s\' used but never initialized"

   * source/compiler/hbpcode.c
     * Enhanced hb_compStrongType() to warn against un-initialized varaiable usage.
2000-05-03 08:45:45 +00:00
Ron Pinkas
78a4a8e84f 20000503-01:00 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/hbpcode.c
     * Fixed hb_compStrongType() to difrentiate between a MEMVAR and a DECLARED FUNCTION with the same name.
     + Added support for HB_P_ARRAYPUSH

   * source/compiler/hbgenerr.c
     * Minor correction to "Incompatibe return type"

   * tests/testwarn.prg
     + Added code to demonstrate more warnings.
2000-05-03 08:00:23 +00:00
Ron Pinkas
d4b1d4c1fd 20000502-23:15 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* include/hbcomp.h
     - Removed members cParamTypes and iParamCount from COMSYMBOL
     + Added member USHORT iStackSize to FUNCTION structure
     * Modified member pStack of FUNCTION to not pre allocate any memory.
     + Added new structure COMDECLARED
     + Added: extern PCOMDECLARED hb_compDeclaredAdd( char * ) and extern PCOMDECLARED hb_compDeclaredFind( char * );
     + Adede: extern PCOMDECLARED  hb_comp_pFirstDeclared and extern PCOMDECLARED  hb_comp_pLastDeclared

   * include/hberrors.h
     + Added:
        #define HB_COMP_DUP_DECLARATION                 17
        #define HB_COMP_DECLARATION_CONFLICT            18

   * source/compiler/genc.c
     * Modified hb_compGenCCode() to free the Declared Function linked list.

   * source/compiler/harbour.c
     + Added: PCOMDECLARED hb_compDeclaredAdd( char * ) and PCOMDECLARED hb_compDeclaredFind( char * );
     + Adede: PCOMDECLARED  hb_comp_pFirstDeclared and PCOMDECLARED  hb_comp_pLastDeclared

   * source/compiler/harbour.y
     * Modified parsing of DECLARE FUNCTION to use new PCOMDECLARED rather than PCOMSYMBOL

   * source/compiler/hbgenerr.c
     + Added:
       "3Duplicate Declaration of Function %s"
       "3Function \'%s\' conflicting with its declaration"

   * source/compiler/hbpcode.c
     * Modifief hb_compStrongType() to utilize PCOMDECLARED rather than PCOMSYMBOL
     * Modifief hb_compStrongType() to increase the pFunc->pStack as needed.

   * tests/testwarn.prg
     + Added code to demonstrate more warnings.
2000-05-03 06:32:02 +00:00
Ron Pinkas
90808e7713 20000501-20:50 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.l
     + Added "as char" and "as string" as acceptable alternative to "as character"
     + Added "as num" as acceptable alternative to "as numeric"
2000-05-02 03:49:18 +00:00
Ron Pinkas
f14599541d 20000501-14:15 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.c
      * Minor correction to hb_compVariableAdd().

    * source/compiler/hbpcode.c
      * Enhancements to hb_compStrongType() to support new PUSH/POPALIASEDFIELDNEAR.

    * tests/testwarn.prg
      + Added code to demonstrate more warnings.
2000-05-01 21:14:35 +00:00
Ron Pinkas
f7f9ded3f0 20000501-01:52 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/hbpcode.c
      * Minor Enhancements to hb_compStrongType()

    * tests/testwarn.prg
      + Added code to demonstrate more warnings.
2000-05-01 08:53:07 +00:00
Ron Pinkas
a10ec0d501 20000501-01:0 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* include/hbcomp.h
      + Added to COMSYMBOL :
         BYTE * cParamTypes;
         int    iParamCount;
      + Added :
        extern char * hb_comp_szDeclaredFun

    * source/compiler/harbour.y
      * Enhanced DECLARE FUNCTION parsing to properly maintain number and type of declared function parameters.

    * source/compiler/harbour.c
      + Added char * hb_comp_szDeclaredFun
      * Modified hb_compVariableAdd() to support dummy parameter vars in Function Decleration.

    * source/compiler/hbpcode.c
      * Enhancements to hb_compStrongType() to support parameter checks of declared function.

    * tests/testwarn.prg
      + Added code to demonstrate more warnings.

    * include/hberrors.h
      + Added :
        #define HB_COMP_PARAM_COUNT                     15
        #define HB_COMP_PARAM_TYPE                      16

    * source/compiler/hbgenerr.c
      + added :
        "3Invalid number of parameters: \'%s\' expected: \'%s\'"
        "3Incompatible parameter # %s expected: \'%s\'"
2000-05-01 08:00:25 +00:00
Ron Pinkas
e0201e2067 20000430-21:30 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.c
      - Removed refrence to pFunc->iFunctionIndex.

    * source/compiler/hbpcode.c
      * Enhancements to hb_compStrongType()

    * tests/testwarn.prg
      + Added code to demonstrate more warnings.

    * include/hberrors.h
      - Removed pFunctionCalls and iFunctionIndex members of _FUNC structure.
2000-05-01 04:37:09 +00:00
Ron Pinkas
f935e3bca5 20000430-22:15 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* harbour/source/compiler/harbour.y
      ! Fixed { hb_compVariableDim( $1, $2 ); } to { hb_comp_cVarType = 'A'; hb_compVariableDim( $1, $2 ); }
	so that correct type is saved.

    * harbour/source/compiler/hbpcode.c
      * Enhancements to hb_compStrongType()

    * harbour/source/compiler/hbgenerr.c
      + added :
        "3Can\'t use array index with NON Array"
        "3Incompatible return value: \'%s\' expected: \'%s\'"

    * harbour/include/hberrors.h
      + added :
        #define HB_COMP_WARN_NOT_ARRAY                  13
        #define HB_COMP_RETURN_TYPE                     14

    * harbour/tests/testwarn.prg
      + Added code to demonstrate more warnings.
2000-05-01 03:31:35 +00:00
Ron Pinkas
4966e9016b 20000429-23:50 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* harbour/source/compiler/harbour.c
      ! Fixed hb_compVariableAdd() to utilize parameter cValueType for Codeblock local variables, so that correct type is stored.

    * harbour/source/compiler/harbour.y
      ! Fixed hb_compExprCBVarAdd( $<asExpr>0, $1, $2 ) to hb_compExprCBVarAdd( $<asExpr>0, $1, hb_comp_cVarType ) and
	hb_compExprCBVarAdd( $<asExpr>0, $3, $4 ) to hb_compExprCBVarAdd( $<asExpr>0, $3, hb_comp_cVarType ) so that
        correct type is passed.
      + Added hb_comp_cVarType = ' ' to reset declared type after BlockVar[s] PRIVATE and PUBLIC.

    * harbour/source/compiler/hbpcode.c
      * Minor corrections to hb_compStrongType()
2000-04-30 06:56:59 +00:00
Ron Pinkas
13c38352c7 20000426-12:30 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* harbour/include/hbcomp.h
       + Added:
         BYTE   pStack[256];              /* Compile Time Stack */
         SHORT   iStackIndex;              /* Compile Time Stack Index */
         BYTE   pFunctionCalls[256];      /* Array of Function Calls Compile Time Stack Postion */
         SHORT  iFunctionIndex;           /* Index into Array of Function Calls Compile Time Stack Postion */

    * harbour/include/hberrors.h
       * Modified Memory Errors to indicate the requested size.
       -* Removed few Strong Type warnings, and modified few others.

    * harbour/include/hbexprb.c
      * Modified all HB_EXPR_PCODE?( hb_compGenPCode1 ,...) to HB_EXPR_GENPCODE?( ... ) to diferntiate between the
        calls top GenPCode?() and the other calls using this macro, since the GenPCode?() now uses additional parameter:
	BOOL bAffectStack
      * Modified all the GenPCode?() to pass additional required paramter.

    * harbour/include/hbexprc.c
      * Modified all HB_EXPR_PCODE?( hb_compGenPCode1 ,...) to HB_EXPR_GENPCODE?( ... ) to diferntiate between the
        calls top GenPCode?() and the other calls using this macro, since the GenPCode?() now uses additional parameter:
	BOOL bAffectStack
      * Modified all the GenPCode?() to pass additional required paramter.

    * harbour/include/hbexprop.h
      + Added macros:
        #define HB_EXPR_GENPCODE1( action, p1 ) action( (p1) )
        #define HB_EXPR_GENPCODE2( action, p1, p2, p3 ) action( (p1), (p2), (p3) )
        #define HB_EXPR_GENPCODE3( action, p1, p2, p3, p4 ) action( (p1), (p2), (p3), (p4) )
        #define HB_EXPR_GENPCODE4( action, p1, p2, p3, p4, p5 ) action( (p1), (p2), (p3), (p4), (p5) )

	And:

        #define HB_EXPR_GENPCODE1( action, p1 ) action( (p1), pMacro )
        #define HB_EXPR_GENPCODE2( action, p1, p2, p3 ) action( (p1), (p2), (p3), pMacro )
        #define HB_EXPR_GENPCODE3( action, p1, p2, p3, p4 ) action( (p1), (p2), (p3), (p4), pMacro )
        #define HB_EXPR_GENPCODE4( action, p1, p2, p3, p4, p5 ) action( (p1), (p2), (p3), (p4), (p5), pMacro )

    * harbour/include/hbmacro.h
       Added:
         extern void hb_compGenPCode1( BYTE, HB_MACRO_DECL );
         extern void hb_compGenPCode2( BYTE, BYTE, BOOL, HB_MACRO_DECL );
         extern void hb_compGenPCode3( BYTE, BYTE, BYTE, BOOL, HB_MACRO_DECL );
         extern void hb_compGenPCode4( BYTE, BYTE, BYTE, BYTE, BOOL, HB_MACRO_DECL );
         extern void hb_compGenPCodeN( BYTE * pBuffer, ULONG ulSize, BOOL, HB_MACRO_DECL );

	 And:
         extern void hb_compGenPCode1( BYTE byte, HB_MACRO_DECL );
         extern void hb_compGenPCode2( BYTE byte1, BYTE byte2, BOOL bStackAffected, HB_MACRO_DECL );
         extern void hb_compGenPCode3( BYTE byte1, BYTE byte2, BYTE byte3, BOOL bStackAffected, HB_MACRO_DECL );
         extern void hb_compGenPCode4( BYTE byte1, BYTE byte2, BYTE byte3, BYTE byte4, BOOL bStackAffected, HB_MACRO_DECL );
         extern void hb_compGenPCodeN( BYTE * pBuffer, ULONG ulSize, BOOL, HB_MACRO_DECL );

	 *** I think this is redundant but I went by exisitng declarations !!! Ryszard Please Check !!!

    * harbour/source/compiler/harbour.c
      * Modified GenPCode2-N() to require additional paramter.
      * Modified GenPCode2-N() to call StrongType() if needed.
      * Modified all the GenPCode?() calls to pass additional required paramter.

    * harbour/source/compiler/harbour.y
      * Modified all the GenPCode?() to pass additional required paramter.

    * harbour/source/compiler/hbgenerr.c
       * Modified Memory Errors to indicate the requested size.
       -* Removed few Strong Type warnings, and modified few others.

    * harbour/source/compiler/hbpcode.c
      Added void hb_compStrongType( int iSize ) - This is the Strong Type Checker! It's not 100% completed but it's stable and the
      approch guarntee 100% accuracy once we fine tune the calculations of the Compile Time Stack to be identical to the R/T Stack.

    * harbour/source/vm/macro.c
      * Modified GenPCode2-N() to require additional paramter.
      * Modified GenPCode2-N() to call StrongType() if needed.
      * Modified all the GenPCode?() calls to pass additional required paramter.

    * harbour/tests/testwarn.prg
      + Added code to demonstrate more warnings.
2000-04-26 20:04:07 +00:00
Ron Pinkas
a3b90dd225 20000425-07:30 GMT-8 Ron Pinkas <Ron@Profit-Master.com>
* source/compiler/harbour.c
     * Replaced sequential calls to hb_compGenPCode3() + hb_compGenPCode3() with 1 call to new hb_compGenPCode4()

   * source/compiler/hbpcode.c
     + Added hb_compGenPCode4( BYTE, BYTE, BYTE, BYTE )

   * include/hbcomp.h
     + Added hb_compGenPCode4( BYTE, BYTE, BYTE, BYTE )

   * source/vm/macro.c
     + Added hb_compGenPCode4( BYTE, BYTE, BYTE, BYTE, HB_MACRO_DECL )
2000-04-25 14:38:23 +00:00
Viktor Szakats
83c6681014 20000403-02:11 GMT+1 Victor Szakats <info@szelvesz.hu> 2000-04-03 00:09:34 +00:00
Viktor Szakats
ed49d952f7 20000306-22:12 GMT+1 Victor Szakats <info@szelvesz.hu> 2000-03-06 21:18:43 +00:00
Viktor Szakats
74d918755f 19991004-19:54 GMT+1 1999-10-04 18:46:41 +00:00