* harbour/include/hbcomp.h
* harbour/include/hbexpra.c
* harbour/include/hbexprb.c
* harbour/include/hbexprc.c
* harbour/include/hbmacro.h
* harbour/include/hbpcode.h
* harbour/include/hbxvm.h
* harbour/source/common/hbdate.c
* harbour/source/compiler/genc.c
* harbour/source/compiler/gencc.c
* harbour/source/compiler/harbour.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* harbour/source/compiler/hbdead.c
* harbour/source/compiler/hbfix.c
* harbour/source/compiler/hblbl.c
* harbour/source/compiler/hbopt.c
* harbour/source/compiler/hbpcode.c
* harbour/source/compiler/hbstripl.c
* harbour/source/rtl/abs.c
* harbour/source/rtl/at.c
* harbour/source/rtl/chrasc.c
* harbour/source/rtl/datec.c
* harbour/source/rtl/dateshb.c
* harbour/source/rtl/diskspac.c
* harbour/source/rtl/disksphb.c
* harbour/source/rtl/gtfunc.c
* harbour/source/rtl/left.c
* harbour/source/rtl/len.c
* harbour/source/rtl/math.c
* harbour/source/rtl/minmax.c
* harbour/source/rtl/mod.c
* harbour/source/rtl/philes.c
* harbour/source/rtl/philesx.c
* harbour/source/rtl/replic.c
* harbour/source/rtl/round.c
* harbour/source/rtl/set.c
* harbour/source/rtl/space.c
* harbour/source/rtl/strcase.c
* harbour/source/rtl/strpeek.c
* harbour/source/rtl/transfrm.c
* harbour/source/rtl/trim.c
* harbour/source/rtl/type.c
* harbour/source/rtl/val.c
* harbour/source/rtl/word.c
* harbour/source/vm/hvm.c
* harbour/source/vm/macro.c
* added some PCODEs to cover all possible combination of ++, --, <op>=
operations in the same way and keep Clipper compatible RT errors.
* added some other PCODEs to optimize some commonly used expressions/
statements
* use HB_ERR_ARGS_BASEPARAMS instead of hb_paramError()
* some other cleanups and minor optimizations
* harbour/utils/hbtest/rt_math.prg
* update expected result for MOD() - it was not Clipper compatible and
it will be hard to make it compatible without introducing some Clipper's
side effects
* harbour/include/hbstdgen.ch
* added #undef HB_COMPAT_XHB
* harbour/source/common/hbstr.c
* indenting
* harbour/source/compiler/ppcomp.c
* updated line numbering in #pragma dump code and error messages
executed for disabled code
* harbour/source/pp/ppcore.c
* changed the precedence of #pragma BEGINDIUMP/ENDDUMP - now
it has higher precedence then conditional compilation with
#IF[DEF]/#ENDIF
* added support for defined() pseudo function in #IF / #ELIF
directives, f.e.:
#if defined( __HARBOUR__ ) .and. !defined( HB_COMPAT_XHB )
#stdout "Harbour compiler compiled without xHarbour extensions."
#endif
* harbour/include/hbexprop.h
* harbour/source/common/expropt1.c
+ added hb_compExprAsNumSign()
* harbour/include/hbexprc.c
* optimize lValue++ and ++lValue
* harbour/source/common/hbdate.c
* minor optimization
* harbour/source/compiler/cmdcheck.c
* maximum supported warning level should be 3 not 4
* harbour/include/hbxvm.h
* harbour/source/compiler/gencc.c
* harbour/source/vm/hvm.c
* use separate functions for equal and exactly equal operations
* cleanup and some other minor optimizations
* harbour/source/compiler/hbopt.c
* optimize PCODEs for code like: lVar:=lVar, sVar:=sVar, mVar:=mVar, ...
* harbour/include/common.ch
* changed HB_SYMBOL_UNUSED( symbol ) to ( symbol := ( symbol ) )
It's a little bit simpler version and now it's also stripped by
PCODE optimizer
* harbour/source/compiler/harbour.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* eliminated some redundant rules
* optimized PCODEs generated for FOR/NEXT code and removed some old
hardcoded optimization for local variables - if it will be worth
to optimize then such optimization will be done by expression
optimizer
* chaned a little bit WITHOBJECT syntax.
Now WITHOBJECT somefunc(); END is not silently ignored and call
to somefunc() is left. This optimization also works when there
are empty line between WITHOBJECT and END
* harbour/source/rdd/dbf1.c
! fixed for GPF in DBRI_RAWDATA, DBRI_RAWMEMOS (Peter Rees fix in
xHarbour)
* harbour/common.mak
* harbour/source/compiler/Makefile
* harbour/source/compiler/hbfix.c
+ harbour/source/compiler/hbopt.c
* divided hbfix.c into two separated functions:
- hb_compFixFuncPCode() which only fix generated PCODE updating
local parameters numbers when PARAMETERS is used
- hb_compOptimizePCode() which makes PCODE optimization
It allows to not execute hb_compFixFuncPCode() when PARAMETERS
is not use and execute hb_compOptimizePCode() more then once in
optimization process.
* harbour/hbgtmk.sh
* updated CVS server name
* harbour/include/hbcomp.h
* harbour/include/hbcompdf.h
* harbour/source/compiler/complex.c
* harbour/source/compiler/harbour.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* harbour/source/compiler/hbcomp.c
* harbour/source/compiler/hbgenerr.c
* harbour/source/compiler/hbident.c
* changed code for generating in PCODE line numbers and module names
there was serious problem with line numbers and module names in old
code - in many cases line numbers were not generated at all or
generated in wrong places. Also file module name was not updated
when inside of function some code was included with #include
For such situation now modified version of HB_P_MODULE is generated
with module name only but without function name, f.e.:
HB_P_MODULE "test.prg:"
exactly the same form of HB_P_MODULE is used in xHarbour.
Debugger code should be updated to recognize such HB_P_MODULE version
Ryszard any chance that you can look at it?
And what about syncing with xHarbour debugger?
I can add some missing functions to compiler and HVM but I do not
want to update next peace of code myself. Sorry but I do not have
enough time. I'd prefer to finish some other things I'm working.
If Ryszard is busy can someone else try to port xHarbour debugger
to Harbour?
* harbour/contrib/libct/ctwfunc.c
* harbour/contrib/libct/ctwin.c
* harbour/contrib/libct/ctwin.h
+ added CTWIN compatible ALERT - it works in differ way then the
standard Clipper one. In the moment when CTWIN is activated
(it's enough to call any CTWIN function like WOPEN()/WBOARD(),...
or CTWINIT()) standard ALERT() is replaced by CTWIN one build
in inside CTWIN GT driver. It allocates separate window for ALERT
box and makes differ formatting of passed text.
TODO: add support for SET KEY blocks
* harbour/bin/hb-func.sh
* do not pass linking parameters to GCC/G++ when is used for
compilation only
* harbour/contrib/rdd_ads/Makefile
* set -DWIN32 for W32 compilation
* harbour/contrib/rdd_ads/makefile.bc
* formatting
* harbour/include/hbapi.h
* harbour/source/rtl/strcase.c
+ added hb_charUpper() and hb_charLower()
* harbour/include/hbapigt.h
* harbour/include/hbgtcore.h
* harbour/source/rtl/gtapi.c
* harbour/source/rtl/hbgtcore.c
+ added support for ALERT() on GT level - C functions: hb_gtAlert()/
hb_gt_Alert()
To replicate some details of Clipper and CT3 behavior ALERT() cannot
be implement only on upper level as .prg function
* harbour/source/rtl/gtfunc.c
+ added .prg function HB_GTALLERT()
* harbour/source/rtl/alert.prg
* redirected ALERT() to HB_GTALLERT()
* harbour/source/rtl/fstemp.c
* use the same case conversion as in low level hb_fs*() functions to
avoid possible problems with national characters
* harbour/source/rtl/dates.c
* harbour/source/rtl/set.c
* harbour/source/rtl/strmatch.c
* harbour/source/rtl/transfrm.c
* use hb_charUpper()
* casting
* harbour/contrib/rdd_ads/ads1.c
* do not release FLOCK() after DBAPPEND() - only RLOCKs should be
removed
* harbour/contrib/rdd_ads/rddads.h
* set ADS_REQUIRE_VERSION when not set by user scripts
* harbour/source/rtl/isprint.c
* harbour/include/hbapi.h
! hb_printerIsReady() C level function made public again.
+ Added proper declaration for it.
* harbour/bin/bld.bat
! Mistakenly committed change undone.
* harbour/include/hbgtinfo.ch
* harbour/contrib/libct/ctwin.c
* harbour/source/rtl/gtalleg/gtalleg.c
* harbour/source/rtl/gtcrs/gtcrs.c
* harbour/source/rtl/gtdos/gtdos.c
* harbour/source/rtl/gtos2/gtos2.c
* harbour/source/rtl/gtpca/gtpca.c
* harbour/source/rtl/gtsln/gtsln.c
* harbour/source/rtl/gtstd/gtstd.c
* harbour/source/rtl/gtwin/gtwin.c
* harbour/source/rtl/gtwvt/gtwvt.c
* harbour/source/rtl/gtxwc/gtxwc.c
+ added support for GTI_FULLSCREEN, GTI_KBDSUPPORT, GTI_ISCTWIN
* harbour/source/rtl/hbgtcore.c
! fixed line and box drawing when the coordinates are out of screen size
* harbour/include/hbapi.h
* harbour/include/hbcomp.h
* harbour/include/hbpcode.h
* harbour/include/hbstack.h
* harbour/include/hbvm.h
* harbour/include/hbxvm.h
* harbour/source/compiler/complex.c
* harbour/source/compiler/genc.c
* harbour/source/compiler/gencc.c
* harbour/source/compiler/harbour.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* harbour/source/compiler/harbour.yyh
* harbour/source/compiler/hbdead.c
* harbour/source/compiler/hbfix.c
* harbour/source/compiler/hblbl.c
* harbour/source/compiler/hbpcode.c
* harbour/source/compiler/hbstripl.c
* harbour/source/vm/classes.c
* harbour/source/vm/estack.c
* harbour/source/vm/hvm.c
* harbour/source/vm/itemapi.c
! added protection against cyclic references in arrays
* eliminated action parameter from hb_vmRequestReenter() /
hb_vmRequestRestore()
* moved s_lRecoverBase and s_uiActionRequest to HB_STACK structure
for future MT HVM version
+ added internal item structure hb_struRecover - it's not real item
but this structure is used to keep information about BEGIN SEQUENCE
data - it reduce HB_STACK usage
+ added support for ALWAYS clause in BEGIN SEQUENCE
The syntax is:
BEGIN SEQUENCE
<code>
[ RECOVER [ USING oErr ] ]
<recoverCode>
[ ALWAYS ]
<alwaysCode>
END [ SEQUENCE ]
It's guaranteed that <alwaysCode> is _ALWAYS_ executed even if
inside <code> or <recoverCode> some new exceptions like RETURN,
BREAK or QUIT will appear.
Please note that when the following code is executed:
BEGIN SEQUENCE
<code>
ALWAYS
<alwaysCode>
END
(without RECOVER clause) then BREAK exception inside <code> is not
recovered, <alwaysCode> is executed and then BREAK exception is
passed to outer BEGIN SEQUENCE. This is the same semantic as
used in TRY / [ CATCH ] / FINALLY / END
Those of you who prefer to use TRY / CATCH / FINALLY / END instead
of BEGIN SEQUENCE / RECOVER / ALWAYS / END can simply add to your
source code:
#command TRY => BEGIN SEQUENCE
#command CATCH [ oErr ] => RECOVER [ USING <oErr> ]
and:
errorBlock( {|oErr| break( oErr ) } )
Though instead of 'break( oErr )' I suggest to use some small function
which will support some basic recovery/substitute operations like in
default errorsys() and LockErrHandler() to not break existing code
which may depends on the default behavior.
If you want I can add direct support for TRY / CATCH / FINALLY / END
but I'm not sure it's really necessary.
Please note also that in Harbour ALWAYS code is execute even for QUIT
excpetion.
When <alwaysCode> is executed current exception is stored and restored
when is finished. If new exception appears inside <alwaysCode> then
restored exception depends on the priority in the following order:
QUIT // highest priority
BREAK
RETURN
If both exceptions have the same priority and contain additional value
(error object in BREAK or return value in RETURN) then the recently set
one is restored. It's similar behavior to destructor code.
* harbour/source/common/hbstr.c
* moved one character length string table (hb_szAscii) from hvm.c
to use it also in compiler and preprocessor
* harbour/source/compiler/ppcomp.c
* harbour/source/pp/ppcore.c
* harbour/source/pp/pplib.c
* tuned error messages to be more Clipper compatible
% use static strings from hb_szAscii
* harbour/source/rtl/alert.prg
* use hb_gtInfo( GTI_FULLSCREEN ) to detect type of GT driver
! some minor fixes
TOFIX: we have to also use GTI_ISCTWIN or add window allocation
to standard GT drivers to be Clipper compatible when CTWIN
is used - In Clipper Tools ALERT() works in differ way then
the standard one. It creates separate window box to display
data, supports SETKEY(), etc. I'll think about adding some
extended support for ALERT() and similar operations (f.e.
separate debugger windows) to GT API so it will be also
possible to overload standard alert() command by GUI message
box in GTGUI and similar GT drivers.
* harbour/source/rtl/binnumx.c
! fixed U2BIN() - wrong casting
* harbour/source/compiler/gencc.c
* harbour/source/vm/hvm.c
! fixed typo in hb_xvmGreaterEqualThenIntIs() - <= was used instead
of >=
! fixed :¯o() messages used in WITH OBJECT structure and -gc3
output
+ added some missing optimizations in -gc3 output
* harbour/contrib/libct/ctc.c
* harbour/contrib/libct/files.c
* harbour/contrib/libnf/ftattr.c
* harbour/contrib/libnf/n2color.c
* cleaned some BCC warnings
* harbour/include/hbapi.h
* harbour/include/hbexpra.c
* harbour/include/hbexprb.c
* harbour/include/hbsetup.ch
* harbour/source/common/expropt1.c
* harbour/source/common/expropt2.c
* harbour/source/common/hbver.c
* harbour/source/common/hbverdsp.c
* harbour/source/compiler/hbcomp.c
* harbour/source/vm/arrays.c
* harbour/source/vm/arrayshb.c
* harbour/source/vm/cmdarg.c
* harbour/source/vm/hvm.c
! fixed Harbour support for accessing string characters with array
index operators []
+ added support for #define HB_COMPAT_XHB - it's disabled by default.
When set it enables some of xHarbour features like negative array
indexes calculated from tail, accessing string characters with []
operators (warning it's not compatible with default Harbour version
enabled by -ks during compilation and //flags:s at runtime - in
xHarbour compatibility mode "ABC"[2] returns "B" when in Harbour 66)
and some other minor features.
* harbour/source/compiler/cmdcheck.c
* added support for optional setting C output type in -go switch
Now it accepts optional digit [0123] after -go in the same way
as -gc, f.e.: -go3
* harbour/source/compiler/harbour.c
* call hb_compExprLstDealloc() only when errors appeared during
compilation - it disable automatic freeing all allocated expressions
in clean compilation. I make it intentionally for easier detecting
problems one some expressions are not freed. So far the final cleanup
code always deallocated expressions what can hide some real bugs.
* harbour/source/vm/hvm.c
! fixed very serious bug in HVM closing. The s_uiActionRequest flag
was not cleared before hb_rddShutDown() so when RDD buffers were
hot and flushing required some PCODE evaluation (f.e. index KEY
or FOR expression) then they were not properly evaluated.
* harbour/source/vm/macro.c
* minor improvement
* harbour/utils/hbtest/rt_misc.prg
! fixed one of expected result, it was neither Harbour nor Clipper
result (I've just made some test with Clipper), I do not know why
it existed
* harbour/contrib/rdd_ads/adsfunc.c
* harbour/source/rdd/workarea.c
* formatting
* harbour/include/hbapi.h
* harbour/source/vm/extend.c
+ added missing hb_storptrGC()
* harbour/include/hbapicdp.h
* harbour/source/rtl/cdpapi.c
+ added parameter to unicode translation function to protect control
code translation
* formatting
* harbour/source/rtl/gtsln/kbsln.c
* harbour/source/rtl/gtxwc/gtxwc.c
* use new unicode translation function format. It also fixes problem
with space translation in GTLSN used in UTF8 mode
* harbour/include/hbapiitm.h
* harbour/source/vm/itemapi.c
+ added hb_itemCopyToRef(), hb_itemMoveToRef(), hb_itemMoveRef(),
hb_itemUnRefWrite()
* harbour/include/hbexprb.c
! use HB_P_DUPLUNREF instead of HB_P_DUPLICATE when assign is used in
push context - Clipper compatible behavior, see:
x:=10
f(y:=iif(.t.,@x,))
? x, y
func f(x)
x+=100
return nil
* harbour/include/hbver.h
* harbour/source/common/hbver.c
* changed status to "devel"
* harbour/source/common/expropt2.c
* disabled setting NIL when iif(.t.,,sth()) is optimized to avoid
warning when iif() is used as statement - to fix number of parameters
passed to function in code like f(iif(.t.,,sth())) we will need a
little bit deeper modification
* harbour/source/compiler/complex.c
* added hack for potential problems caused by WITH OBJECT syntax, f.e.
in code like:
proc p(obj,x)
case:=myCaseClass():new()
retu:=myCaseClass():new()
WITH OBJECT obj
do case
case x==nil
case:value()
case:action()
retu:sth()
end
END
case:action()
retu:sth()
return
case:action(), case:value(), retu:sth() can means two different things
and compiler cannot guess which one should use. It cannot be fixed
because it's caused by bad WITH OBJECT syntax. In xHarbour constractions
like case:value() or retu:sth() are always used as in WITH OBJECT
context what is not Clipper compatible. I do not want to introduce
such limitations. We have two choices: change WITH OBJECT syntax or
add some hack to "hide" the problem a little bit. Now I intorduce
ugly hack which check number of spaces between ':' so
case :action()
is compiled as case condition using WITH OBJECT message and
case:action() as sending message to object in case variable
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
+ added support for passing base value to FOR EACH by reference.
* harbour/source/vm/arrays.c
* use hb_itemMoveRef() in AINS()/ADEL() to avoid creation of cyclic
reference chains
* harbour/source/vm/debug.c
* harbour/source/vm/memvars.c
* use hb_itemCopyToRef() to avoid creation of cyclic reference chains
* harbour/source/vm/classes.c
* harbour/source/vm/hvm.c
* use hb_itemMoveToRef() to avoid creation of cyclic reference chains
+ added support for for writable string enumerators, f.e.:
proc main()
local s, c
s:="abcdefghijklmnopqrst"
for each c in @s
if c$"aeio"
c:="*"
endif
next
? s // "*bcd*fgh*jklmn*pqrst"
return
* harbour/ChangeLog
+ harbour/ChangeLog.017
* new ChangeLog file created
* harbour/doc/whatsnew.txt
* harbour/harbour.spec
* harbour/include/hbver.h
* updated version number to 0.47.0
* tagged CVS as build47
* harbour/ChangeLog
+ harbour/ChangeLog.017
* new ChangeLog file created
* harbour/doc/whatsnew.txt
* harbour/harbour.spec
* harbour/include/hbver.h
* updated version number to 0.47.0
* tagged CVS as build47
* harbour/ChangeLog
+ harbour/ChangeLog.017
* new ChangeLog file created
* harbour/doc/whatsnew.txt
* harbour/harbour.spec
* harbour/include/hbver.h
* updated version number to 0.47.0
* tagged CVS as build47
* harbour/source/compiler/hbusage.c
* update the year in hb_compPrintLogo() from 2006 to 2007
* harbour/source/vm/garbage.c
! fixed potentially very serious bug - when I added array items
references I forgot to update GC. Fortunately it was caught
by code to detect bugs in object destructors so only RT error
was reported instead of internal HVM memory corruption
* harbour/tests/hbinline.prg
* updated comments
* harbour/include/hbexpra.c
! fixed GPF which can appear on syntax error during compilation
one of enumerator message
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* accept the folowing syntax: (@var):msg
With this modification FOR EACH overloading is completed.
* harbour/source/vm/hvm.c
* small modification to protect against creating long references chains
which can hardly reduce the performance in some cases
* harbour/include/hbcomp.h
* harbour/include/hbexpra.c
* harbour/include/hbexprb.c
* harbour/include/hbexprc.c
* harbour/include/hbexprop.h
* harbour/source/common/expropt1.c
* harbour/source/common/expropt2.c
* harbour/source/compiler/Makefile
* harbour/source/compiler/cmdcheck.c
* harbour/source/compiler/harbour.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* harbour/source/compiler/harbour.yyh
* harbour/source/compiler/hbcomp.c
* harbour/source/compiler/hbusage.c
* harbour/source/compiler/ppcomp.c
* harbour/source/macro/Makefile
* harbour/source/macro/macro.y
* harbour/source/macro/macro.yyc
* harbour/source/macro/macro.yyh
* harbour/source/vm/macro.c
* harbour/source/vm/memvars.c
* harbour/source/vm/memvclip.c
* keep prefix definition for bison public symbols in *.y files instead
of passing them as bison arguments to avoid possible mistakes during
*.yy[hc] file generation
! fixed iif() reduction when used as single function parameter
+ add -kM compiler switch - turn off macrotext substitution
* updated <string> + <string> optimization and other macrotext usage
to keep more Clipper compatible behavior
! fixed typo in expression type checking in IIF() reduction - it was
working because wrongly used macros has the same values as the valid
ones
- removed compiler switches and macros for old HB_INLINE() syntax - it
was not supported after last months modifications. Only:
HB_INLINE([params,...]) { C code }
is supported.
! fixed passing parameters by reference in IIF() statement and macro
compiler. The following valid Clipper code:
&("myfunc(<exp>, @var1, @var2)")
was not supported
! do not allow to use references or empty expressions in expression list
AFAIK it's Clipper compatible. If I'm wrong then please fix me but
Clipper allows to use references only as function arguments, 2-nd and
3-rd IIF() argument and as directly created array items ( {...@var...} )
DO ... WITH ... is a special case of function call.
! Changed grammar rules to accept only Clipper compatible parameters.
! fixed typo in macro name in hb_memvarNewParameter() function.
* use HB_FUNC_EXEC(...) instead of HB_FUNCNAME(...)()
* harbour/include/hbexprb.c
* make function call optimizations only when hb_compFunCallCheck()
do not report errors
* harbour/source/common/reserved.c
+ added VALTYPE to list of reserved words and shortcuts (Clipper
compatible)
* harbour/source/compiler/hbfunchk.c
* checking for number of parameters in FILE() function call is Harbour
extension - do not enable it when HB_C52_STRICT macro is set
* harbour/source/rtl/filehb.c
* formatting
* harbour/include/hbcompdf.h
+ added comment
* harbour/include/hbexpra.c
* change expression type for <exp> = <exp> from HB_EO_EQUAL
to HB_EO_ASSIGN in hb_compExprGenStatement() function so
later we can safely make all optimization in hb_compExprUseEqual()
during reduce process - optimization only when PCODE is generated
is too late and causes that expressions like:
iif( 1 = 1, <exp>, <exp> )
are not reduces (Clipper reduce them)
* do not execute hb_compFunCallCheck() in hb_compExprNewFunCall()
to avoid repeating the same error message in hb_compExprUseFunCall()
* harbour/include/hbexprb.c
* enabled reduction for hb_compExprUseEqual() and generate errors
when it's used as statement
* harbour/source/common/expropt2.c
* added some missing reductions for expressions like: NIL == NIL
* harbour/source/common/reserved.c
% very basic optimization: use binary search instead of linear
scanning for reserved words and shortcuts - it gives noticeable
speed improvement in macro compiler
* harbour/source/compiler/complex.c
* changed the order of special keywords to keep alphabetic sorting
* harbour/source/compiler/harbour.c
% some minor optimizations in aliased expressions
! added protection in hb_compIsJump() to avoid possible problems
when this function is executed after replacing some code with
jumps by series of NOOPs in optimizations process
* harbour/source/compiler/hbfix.c
* better optimization of PCODE generated for logical expressions
* harbour/source/compiler/hbfunchk.c
% use binary search instead of linear scan
* harbour/source/rtl/minmax.c
! fixed GPF when MIN() or MAX() function is called with less then
two parameters
* harbour/source/vm/itemapi.c
* minor optimization and formatting
* harbour/include/hbcomp.h
* harbour/include/hbcompdf.h
* harbour/include/hbexpra.c
* harbour/include/hbexprb.c
* harbour/source/common/expropt1.c
* harbour/source/compiler/harbour.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* harbour/source/compiler/hbgenerr.c
* harbour/source/macro/macro.l
* harbour/source/macro/macro.y
* harbour/source/macro/macro.yyc
* harbour/source/macro/macro.yyh
* harbour/source/macro/macrolex.c
* harbour/source/vm/macro.c
* final grammar cleanup: removed unused and/or unnecessary grammar
expressions in *.y files, fixed some differences between compiler
and macrocompiler, fixed some other bugs, typos, clipper
incompatibilities, etc.
It's end of year, it's late and sorry but I'd like to begin making
something absolutely differ then creating detail description ;-)
If you will have any questions then I'll answer in new year.
* harbour/source/rdd/dbffpt/Makefile
* small hack for XCC compilation
best regards and happy new year,
Przemek
* harbour/include/hbcomp.h
* harbour/include/hbcompdf.h
* harbour/include/hbexprb.c
* harbour/include/hbexprc.c
* harbour/include/hbpcode.h
* harbour/include/hbpp.h
* harbour/include/hbxvm.h
* harbour/source/compiler/genc.c
* harbour/source/compiler/gencc.c
* harbour/source/compiler/gencli.c
* harbour/source/compiler/harbour.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* harbour/source/compiler/hbgenerr.c
* harbour/source/compiler/hbpcode.c
* harbour/source/vm/hvm.c
* harbour/source/vm/macro.c
* changed HB_P_MACROPUSHINDEX PCODE behavior - now it does not evaluated
macro expression
* eliminated HB_ET_MACRO_INDEX - HB_ET_MACRO_LIST can be used instead
* accept ... in codeblocks only when codeblocks parameters are defined
as variables, f.e: {|a,b,...|qout(a+b,...)}
! fixed error in a[&s]:=100
+ added support for a[...] - now ... can be used in the same context as
xbase++ like multivalue macro (a[&s])
* disabled ++, --, <op>= optimizations when -kc (strict Clipper
compatibility mode) compiler switch is used
* harbour/include/hbcompdf.h
* removed not longer used pFunCall from asMacro expression.
This item was used only in a very old s:="1,2";f(&s) implementation.
* harbour/include/hbexpra.c
* harbour/include/hbexprb.c
* harbour/include/hbexprop.h
* harbour/source/common/expropt1.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* a little bit more simple implementation of passing optional arguments
and simplified some code. Now they can be used in any place in argument
list (also repeated). It's also possible to create arrays using "..."
as array element(s), f.e.: func f(...); return { "{", ..., "}" }
If you think it will be usable then I can also add support for accessing
array items with optional parameters, f.e.: ? a[ ... ]
so it can be used in the same context as xbase++ like macro lists
but for this I will need new PCODE so I'd like to hear your opinion
ASAP - I'm closing any extensions today.
* harbour/include/hbcomp.h
* harbour/include/hbcompdf.h
* harbour/include/hberrors.h
* harbour/include/hbexpra.c
* harbour/include/hbexprb.c
* harbour/include/hbpcode.h
* harbour/include/hbxvm.h
* harbour/source/common/expropt1.c
* harbour/source/compiler/genc.c
* harbour/source/compiler/gencc.c
* harbour/source/compiler/harbour.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* harbour/source/compiler/hbdead.c
* harbour/source/compiler/hbfix.c
* harbour/source/compiler/hbgenerr.c
* harbour/source/compiler/hblbl.c
* harbour/source/compiler/hbpcode.c
* harbour/source/compiler/hbstripl.c
* harbour/source/vm/hvm.c
+ added support for passing optional parameters to called function, f.e.:
proc p( a, b, ... )
qout( a, b, "X", ... )
* forbid creating function pointer when function is used with parameters,
f.e.: x:=@f1(1,2,3)
* harbour/source/compiler/complex.c
* cleaned all restrictions on reserved words I've found - if I missed
sth then please inform me. The previous behavior and some error
messages are used with -kc compiler switch
* harbour/source/rtl/symbol.prg
* harbour/source/rtl/tobject.prg
! eliminated limitations in number of constructor parameters
(new syntax with passing optional parameters used)
* harbour/include/hbcompdf.h
* harbour/include/hbexprb.c
* harbour/source/common/expropt1.c
* harbour/source/compiler/harbour.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* harbour/source/compiler/hbcomp.c
- removed not longer used fExternal from compiler structure
* allow to pass array items by reference ( func(@a[1]) ) and some
cleanups in reference rules. Probably we should also block using:
@func(param1 [,param2,[,...paramN]])
and accept only @func()
! fixed using statements in codeblocks used to initialize static
variables and some other cleanups (f.e. allow to use as static
initializers any functions which are later eliminated by expression
optimizer.
* harbour/include/hbexprb.c
* do not generate HB_P_FUNCPTR - it's not longer necessary
+ added optimization for <exp> + 1, <exp> - 1 - disabled by default
because it changes error messages in hbtest, code like NIL + 1
generates 'argument error ++' instead of 'argument error +'. I'd like
you will decide what you prefer - faster code or strict Clipper error
messaged.
* harbour/source/common/expropt2.c
+ added optimizations for <num> + <date>
+ added ooptimizations for <exp> + 0, 0 + <exp>, <exp> - 0
This is also sth what may interact with operators overloading in object
system. When we will have strong typing then we should think about an
option which will optionally disable some optimizations - someone may
want to define arithmetic where <obj> + 0 gives differ then <obj>
results.
* harbour/include/hbcomp.h
* harbour/source/compiler/harbour.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* harbour/source/compiler/harbour.yyh
+ added hb_compStatmentStart()
! restrict MEMVAR and FIELD usage - now they have to be located before
executable statements like in Clipper.
! generate error when PARAMETERS is used as file wide declaration.
! generate errors when different executable statements are used before
first procedure - now such code was simply ignored without any errors.
! generate valid error messages when some declarations are used in
wrong places
! fixed setting begin of executable statement flag in different .prg
constructions.
* harbour/contrib/rdd_ads/adsfunc.c
* do not use hb_param( pItem, HB_IT_BYREF ) but ISBYREF() macro
* harbour/include/hbdefs.h
* formatting
* harbour/include/hbexprb.c
! fixed code generated for logical expressions when shortcutting
is enabled to be Clipper compatible
* harbour/source/compiler/cmdcheck.c
! added missing break in -z compiler switch decoding
* harbour/source/compiler/hbfix.c
% added optimizations for code generated for logical expressions,
it strips a chain of HB_P_DUPLICATE -> HB_P_JUMP[TRUFALES] ->
HB_P_DUPLICATE -> HB_P_JUMP[TRUFALES] -> ...
In fact it should not be done here but because we do not have
any metacode level where such optimizations should be done and
PCODE is generated online then it will have to be here. Maybe
in the future we will add metacode.
* harbour/source/rdd/dbcmd.c
* make "M" alias Clipper compatible. After some thoughts I decided
that in some cases it can be usable so now "M" will set WA number
to 65535 like in Clipper.
* harbour/source/rdd/dbf1.c
* allow to open VFP DBFs with _NullFlags system command
* harbour/source/rdd/delim1.c
* harbour/source/rdd/sdf1.c
! updated field size calculation for some some extended types.
* harbour/source/rdd/workarea.c
* generate RT error when CREATEFIELD() method does not accept some
parameters to avoid silent DBCREATE() failing.
* harbour/source/vm/macro.c
* removed hb_compMemvarCheck() - this function was not dooing
anything - only slows the TYPE() by calling hb_dynsymFind()
one or two times.
+ added TODO note: memvars create by TYPE() have PUBLIC scope
in Clipper. Clipper also always tries to evaluate valid expressions
inside TYPE even if the contain UDF. UDF only stops evaluation
so:
TYPE( "(val:=1) + f() + (val2:=2)" )
creates in clipper public variable VAL but not VAL2.
* harbour/contrib/rdd_ads/adsfunc.c
* do not use hb_param( pItem, HB_IT_BYREF ) but ISBYREF() macro
* harbour/include/hbdefs.h
* formatting
* harbour/include/hbexprb.c
! fixed code generated for logical expressions when shortcutting
is enabled to be Clipper compatible
* harbour/source/compiler/cmdcheck.c
! added missing break in -z compiler switch decoding
* harbour/source/compiler/hbfix.c
% added optimizations for code generated for logical expressions,
it strips a chain of HB_P_DUPLICATE -> HB_P_JUMP[TRUFALES] ->
HB_P_DUPLICATE -> HB_P_JUMP[TRUFALES] -> ...
In fact it should not be done here but because we do not have
any metacode level where such optimizations should be done and
PCODE is generated online then it will have to be here. Maybe
in the future we will add metacode.
* harbour/source/rdd/dbcmd.c
* make "M" alias Clipper compatible. After some thoughts I decided
that in some cases it can be usable so now "M" will set WA number
to 65535 like in Clipper.
* harbour/source/rdd/dbf1.c
* allow to open VFP DBFs with _NullFlags system command
* harbour/source/rdd/delim1.c
* harbour/source/rdd/sdf1.c
! updated field size calculation for some some extended types.
* harbour/source/rdd/workarea.c
* generate RT error when CREATEFIELD() method does not accept some
parameters to avoid silent DBCREATE() failing.
* harbour/source/vm/macro.c
* removed hb_compMemvarCheck() - this function was not dooing
anything - only slows the TYPE() by calling hb_dynsymFind()
one or two times.
+ added TODO note: memvars create by TYPE() have PUBLIC scope
in Clipper. Clipper also always tries to evaluate valid expressions
inside TYPE even if the contain UDF. UDF only stops evaluation
so:
TYPE( "(val:=1) + f() + (val2:=2)" )
creates in clipper public variable VAL but not VAL2.
* harbour/include/hbexprop.h
* harbour/source/common/expropt1.c
+ added hb_compExprParamListLen()
* harbour/include/hbexpra.c
* harbour/include/hbexprb.c
* use hb_compExprParamListLen()
* harbour/include/hbexprc.c
* generate error message for syntax like:
o:var()++ or o:var()+=10
only:
o:var++ and o:var+=10
is supported, just like for @o:var
* harbour/include/hbapi.h
* harbour/source/common/hbstr.c
+ hb_numDecConv() used to convert double value to/from binary integer
fields with fixed number of decimal places
* harbour/common.mak
* harbour/include/hbapicdp.h
* harbour/source/codepage/Makefile
+ harbour/source/codepage/cptrdos.c
+ harbour/source/codepage/cptrwin.c
* harbour/source/lang/Makefile
+ harbour/source/lang/msgtrdos.c
+ harbour/source/lang/msgtrwin.c
+ added Turkish CPs and MSGs created by Bicahi Esgici
+ harbour/source/codepage/uc1254.c
+ harbour/source/codepage/uc857.c
+ added unicode tables for Turkish CPs
* harbour/source/rdd/dbf1.c
* harbour/source/rdd/workarea.c
+ added support for decimal places in binary integer fields ("I")
! fixed currency field decoding ("Y") - it's integer binary value
not IEEE758 double. Warning: on write the value is rounded not
truncated like in VFP.
* harbour/include/hbexprc.c
* added support _" prefix when macro message is used in assignment context
also when -kc is used. We can block this feature for -kc but as long
as is not blocked it should work in the same way for -kc and -kh
* harbour/config/w32/bcc32.cf
* cleanup
+ harbour/config/w32/xcc.cf
+ added XCC support
* harbour/contrib/btree/hb_btree.c
* use hb_vmAtInit()/hb_vmAtExit() instead of INIT/EXIT functions defined
from C code
* harbour/contrib/libct/tab.c
* casting
* harbour/contrib/odbc/odbc.c
! removed #include <malloc.h> - it should not be used with new C
compilers
I think that we should replace this library with hbodbc from xHarbour.
* harbour/contrib/ole/ole2.c
* updated for XCC
* harbour/include/hbdefs.h
* include stdint.h if available
* harbour/source/compiler/complex.c
! fixed yet another stupid mistake in WITHOBJECT token
* harbour/include/hbpcode.h
* harbour/include/hbxvm.h
* harbour/source/compiler/genc.c
* harbour/source/compiler/gencc.c
* harbour/source/compiler/hbdead.c
* harbour/source/compiler/hbfix.c
* harbour/source/compiler/hblbl.c
* harbour/source/compiler/hbpcode.c
* harbour/source/compiler/hbstripl.c
* harbour/source/vm/hvm.c
+ added HB_P_SWAP <n> PCODE
* harbour/include/hbcompdf.h
* harbour/include/hbexpra.c
* harbour/include/hbexprb.c
* harbour/include/hbexprc.c
* harbour/include/hbexprop.h
! fixed GPF during compilation of @:var, @:&var, @o:&var
+ added support for @o:&var and @:var, @:&var inside WITH OBJECT
statement
* changed PCODE generated of ++,--,+=,-=,...
Now left side expression is evaluated _ONLY_ once and when object
messages are used it's guarantied that exactly the same object
variable will be used. It also fixes some problems which exists
in Clipper. This optimization is enabled by -kh flag (by default)
and can be disabled with -kc.
% optimize ald macros in ++,--,+=,-=,... operations
* add automatically "_" prefix when macro message is used in assignment
context, f.e.:
s:="osCode"
o:=errorNew()
? o:&s
o:&s := 100
? ++o:&s
? o:&s *= 5
* harbour/include/hblang.ch
- removed #xtranslate - this file is included by C code and some C
compiler do not like unknown directives
* harbour/utils/hbtest/rt_math.prg
+ added test code for <op>assign and (pre/post)(inc/dec)rementation,
macro messages and WITH OBJECT
* harbour/source/compiler/harbour.c
* harbour/source/rdd/dbf1.c
* harbour/source/rtl/errorapi.c
* harbour/source/rtl/hbgtcore.c
* harbour/source/rtl/gtdos/gtdos.c
* harbour/source/rtl/gtos2/gtos2.c
* harbour/source/rtl/gtpca/gtpca.c
* harbour/source/rtl/gtsln/gtsln.c
* harbour/source/rtl/gtstd/gtstd.c
* harbour/source/rtl/gtwin/gtwin.c
* casting and warning cleanup
* harbour/utils/Makefile
+ added $(HB_UTILS)
- harbour/utils/hbpp/hbpp.h
+ harbour/utils/hbpp/hbppdef.h
* harbour/utils/hbpp/hbpp.c
* harbour/utils/hbpp/hbppcomp.c
* harbour/utils/hbpp/hbppcore.c
* harbour/utils/hbpp/hbpplib.c
* harbour/utils/hbpp/hbpptbl.c
* harbour/utils/hbpp/pragma.c
* renamed hbpp.h to hbppdef.h to avoid possible conflict with hbpp.h
in include directory
* casting and warning cleanup
* harbour/include/hbapi.h
* harbour/include/hbcomp.h
* harbour/include/hbcompdf.h
* harbour/include/hbdefs.h
* harbour/include/hberrors.h
* harbour/include/hbexpra.c
* harbour/include/hbexprb.c
* harbour/include/hbexprc.c
* harbour/include/hbpcode.h
* harbour/include/hbxvm.h
* harbour/source/common/expropt1.c
* harbour/source/common/expropt2.c
* harbour/source/common/hbstr.c
* harbour/source/compiler/cmdcheck.c
* harbour/source/compiler/genc.c
* harbour/source/compiler/gencc.c
* harbour/source/compiler/gencobj.c
* harbour/source/compiler/harbour.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
* harbour/source/compiler/hbdead.c
* harbour/source/compiler/hbfix.c
* harbour/source/compiler/hbgenerr.c
* harbour/source/compiler/hblbl.c
* harbour/source/compiler/hbpcode.c
* harbour/source/compiler/hbstripl.c
* harbour/source/macro/macro.y
* harbour/source/macro/macro.yyc
* harbour/source/rtl/console.c
* harbour/source/rtl/isprint.c
* harbour/source/rtl/left.c
* harbour/source/rtl/right.c
* harbour/source/rtl/strtran.c
* harbour/source/vm/codebloc.c
* harbour/source/vm/hvm.c
* harbour/source/vm/macro.c
* general PCODE cleanup and address most of TODO/TOFIX notes in
source code:
! fixed GPF traps when too long string or codeblock is generatd
+ added support for 16MB codeblocks and strings
! removed macrocompiler limitation for jumps range
! fixed GPF when more then 255 local variables is used and added
support for 2^15 locals
! removed all strtok() functions
% added optimization for all +=, -=, *=, %=, ^=, **= operations
when left side of expression is variable or array item
% added optimization for all +=, -=, *=, %=, ^=, **= operations
when left side of expression is object method and updated ++, --
for new code. It's still disabled until we will not add support
for late evaluated reference items to HVM
! fixed a[++i]++ and similar operations (a[++i]*=2, ...). Now ++i is
executed only once. It's not Clipper compatible but it was in
TODO note in source code. It can be disabled by -kc option
* finished support to xHarbour like #pragma TEXTHIDDEN(1)
! fixed local add int optimization when PARAMETERS used after
optimization changed local variable number over 255
! fixed GPF trap when in HB_P_<op>EQ PCODEs when executed for
direct values
* others
! fixed problems reported by Chen
* optimized strtran(), left(), right() to not create new string copy
when the same value is returned
* harbour/source/rtl/console.c
* pacify false CG error messages - Chen Kedem modifications (sizeof(int)
in #if replaced by hardcoded 4 for compilers which does not allow to
use sizeof() in #if directives)
* harbour/TODO
- removed console.c cleanup note from TOFIX
* harbour/include/hbcomp.h
* harbour/include/hbexprb.c
* harbour/include/hbexprc.c
* harbour/source/common/expropt1.c
* minor code cleanup
* harbour/include/hbstack.h
! fixed typo in function name, should be: hb_stackLocalVariable()
not hb_stacklocalVariable()
+ added hb_stackId()
* hide hb_stack declaration when HB_STACK_MACROS is not set
* harbour/source/vm/dynlibhb.c
* use hb_stackId()
* harbour/source/vm/estack.c
+ added hb_stackId()
! fixed some condition used to check stack access - they were
reporting internal errors for valid code
* harbour/source/vm/hvm.c
! fixed code which executed hb_stackLocalVariable() with pointer
to SHORT not int
* harbour/source/rtl/memoline.c
! added fix sent to me by Randy Portnoff - it's a little bit differ
then the one Randy sent to list but this one seems to be correct.
I never used this function in Clipper and made only very basic
tests. I believe that Randy make better tests and this fix will
not break some other constructions.