* harbour/common.mak
* harbour/source/lang/Makefile
+ harbour/source/lang/msgskiso.c
+ harbour/source/lang/msgskwin.c
+ harbour/source/lang/msgskkam.c
+ harbour/source/lang/msgsk852.c
+ added Slovak national messages by Gyula Bartal - many thanks
* harbour/include/hbapi.h
* harbour/source/vm/arrays.c
! Guarded hb_arraySetNLL() declaration with #ifndef HB_LONG_LONG_OFF.
! Fixed trace in hb_arraySetNInt().
By Phil Krylov borrowed from xHarbour
* harbour/include/hbgtcore.h
! added missing HB_EXTERN_BEGIN / HB_EXTERN_END
By Ron Pinkas borrowed from xHarbour
* harbour/source/rtl/gtos2/gtos2.c
% updated for much faster screen updating in OS2 console - many
thanks for Maurilio Longo for tests and code.
* harbour/source/rtl/cdpapi.c
! fixed CP string translation for CPs with accented equal characters
+ added HB_UTF8CHR( <nUniVal> ) -> <cUtf8Char>
It's compatible with the function HB_UTF8CHR() by Phil Krylov in
xHarbour
* harbour/source/rtl/gtsln/gtsln.h
* removed repeated #include <unistd.h>
* harbour/contrib/hbct/files.c
! fixed FILESEEK() called with 3-rd parameter set to .T. (exact
attribute match)
* harbour/config/os2/global.cf
! added fixes by David Arturo Macias Corona
+ harbour/make_os2_gcc.cmd
+ added build file for GCC OS2 users with minimal environment settings
* harbour/source/rtl/cdpapi.c
! fixed unicode values for control codes in default CP437 unicode table
* harbour/source/rtl/gtchrmap.c
! added missing default translation of chr(155) - it's control code
on most of terminals and should not be shown in non UFT-8 mode
* harbour/source/rtl/gttrm/gttrm.c
! do not use alternate character set for box drawing in UTF-8 mode
New Linux consoles disable UTF-8 mode when alternate character set
is enabled
* harbour/contrib/hbct/ctwin.c
* harbour/contrib/hbct/ctwin.h
* harbour/contrib/hbct/ctwfunc.c
* overload ReadKey() method for future window moving when scroll lock
is set and for KEYREAD() implementation.
* store real last key value in CTWIN GT.
* harbour/common.mak
* harbour/source/codepage/Makefile
+ harbour/source/codepage/cpesmwin.c
- harbour/source/codepage/cpesmwi.c
* renamed
* harbour/source/rtl/cdpapi.c
! do not use '~' as accented character marker if neither ACCENTED_EQUAL
nor ACCENTED_INTERLEAVED is set - in some CPs '~' is a letter
! use '~' as accented character marker only if it exists in UPPER and
LOWER letter sets - our CP code cannot properly decode letter sets
when this condition is not true - it should be fixed (TOFIX)
! use '.' as multibyte character marker only if it exists in UPPER and
LOWER letter sets - our CP code cannot properly decode letter sets
when this condition is not true - it should be fixed (TOFIX)
* harbour/source/codepage/cpeldos.c
* harbour/source/codepage/cpelwin.c
* updated accent marker upper letters to be the same as in lower ones
Greek users should fix me.
* harbour/source/rtl/cdpapi.c
* some minor speed improvement
* harbour/source/rdd/dbfntx/dbfntx1.c
* harbour/source/rdd/dbfcdx/dbfcdx1.c
* use hb_cdpSelect() instead of direct accessing hb_cdp_page variable
* harbour/source/rtl/cdpapi.c
* changed accented character handling and multibyte character
comparison to make some operations like:
dbSeek(cVal)
while ordKeyVal() = cVal
...
enddo
safe also with such CDPs
* harbour/include/hbapicdp.h
* harbour/source/rtl/cdpapi.c
+ added hb_cdpGetChar()
+ harbour/tests/wcecon.prg
+ added demonstration console program for WinCE,
compile it using:
hbmk -n -w -es2 -gtwvt wcecon
* harbour/include/hbwince.h
* harbour/source/common/hbwince.c
* harbour/contrib/win32/w32_ole.c
* harbour/contrib/odbc/odbc.c
* use UNICODE macro instead of HB_WINCE to allow using Unicode
WINAPI also in other MS-Windows versions
* harbour/source/rtl/gtwvt/gtwvt.h
* harbour/source/rtl/gtwvt/gtwvt.c
+ added support for Unicode IO
* harbour/source/rtl/diskspac.c
* harbour/source/rtl/disksphb.c
! fixed wrongly set error code
! fixed possible access to uninitialized memory
* use GetDiskFreeSpaceEx() on WinCE instead of GetDiskFreeSpace()
for disk larger then 4GB - I do not know if PocketPC have such
large devices now or if WinCE can support it but for sure it will
somewhere in the future
* harbour/source/rtl/cdpapi.c
! fixed possible GPF and some other problems in HB_TRANSLATE()
* harbour/source/rtl/dateshb.c
* harbour/source/rtl/datesx.c
* harbour/source/common/hbdate.c
* make STOD() exact Clipper compatible
* harbour/include/hbgtinfo.ch
+ added GTI_ADDKEYMAP and GTI_DELKEYMAP
* harbour/include/hbapicdp.h
* harbour/source/rtl/cdpapi.c
+ added const to declarations of some function parameters
* harbour/include/hbgtcore.h
* harbour/source/rtl/Makefile
+ harbour/source/rtl/gtchrmap.c
* harbour/source/rtl/gtcrs/Makefile
- harbour/source/rtl/gtcrs/chrmap.c
* harbour/source/rtl/gtcrs/gtcrs.c
* harbour/source/rtl/gtcrs/gtcrs.h
* hb_gt_chrmapinit() common function now for different GT drivers
* minor cleanup in GTCRS code
* harbour/include/hbcompat.ch
+ added some new translation rules
* harbour/include/hbapi.h
* cleanup comment
* harbour/source/pp/ppcore.c
! fixed line numbering when errors are reported in different order
due to preprocessing extended code block
+ harbour/source/rtl/gttrm
+ harbour/source/rtl/gttrm/Makefile
+ harbour/source/rtl/gttrm/gttrm.c
+ added new GT driver - it's terminal driver like GTCRS and GTSLN
but it does not use any external library like [N]CURSES or SLANG
so it can be compiled in nearly all POSIX systems. It's not such
flexible like curses or slang base drivers because instead of
using termcap/terminfo databases to extract terminal capabilities
it uses some hard coded sequences for few terminals (now Linux, ANSI,
XTERM) but it should cover users requests in 95% of cases. Terminals
I tested are quite well supported (GTTRM works even better then GTCRS
or GTSLN and is much faster in full screen mode - 2-4 times).
I noticed that most terminal emulators works much better with GTTRM
then with GTCRS or GTSLN due to limited list of used escape sequences
so some minor differences in each terminal implementation are not
noticeable. GTTRM automatically detects ISO/UTF8 terminal mode and
chose valid output what should also help *nix users.
Now I would like to ask BSD and MacOSX users to test GTTRM in these
systems with pure text console and XWindow terminal emulators. I'm
interesting in any problems you may found.
* harbour/source/vm/hvm.c
+ added protection for possible GPF caused by wrong .prg code
* harbour/source/vm/maindllp.c
% store function addreses in static variables to improved execution
speed
+ added support for compilers which does not use "_" as function prefix
+ added support for using with harbour*.dll
* harbour/source/vm/memvars.c
+ added new method of detaching enumerators and array item references
covered by HB_COMPAT_XHB macro. xHarbour does not work in such way
but the final results are similar.
* harbour/source/vm/dynlibhb.c
+ added protection against passing wrong pointer items to HB_LIB*()
functions
* harbour/source/common/reserved.c
* cleaned warning
* harbour/bin/hb-func.sh
* harbour/config/hpux/global.cf
* harbour/config/darwin/global.cf
* harbour/config/linux/global.cf
* harbour/config/sunos/global.cf
* harbour/config/bsd/global.cf
+ added GTTRM to library list
* harbour/source/codepage/cp_tpl.c
+ Added NOTE about the fact that hb_Translate()
(and hb_cdpTranslate()) would only work properly
if all codepages for the same language are using the
exact same number of lowercase/uppercase cp chars
in the exact same order.
* harbour/source/codepage/Makefile
* harbour/common.mak
* harbour/source/codepage/cphu852.c
* harbour/source/codepage/cphu852s.c
* harbour/source/codepage/cphuiso.c
+ harbour/source/codepage/cphuisos.c
* harbour/source/codepage/cphuwin.c
+ harbour/source/codepage/cphuwins.c
! Synced HU WIN and HU ISO codepage lower/uppercase
strings with HU 852, so that hb_Translate() works
properly. (this means there are now several duplicate
chars included in the WIN/ISO versions, along with
a non-HU char, all just needed to stay compatible with
original CA-Cl*pper HU/852 index ordering and keep
hb_Translate() working at the same time.)
IMO, we'd need to introduce a separate "collation"
string in each cp file to detach index ordering
from upper/lowercase and codepage translation without
any hacks, since as this example shows these two
are not always in sync. (or, as an alternative we might
want to make codepage translation more sophisticated,
like converting first to unicode and convert back to
the other codepage from unicode, but that leads a bit
further.). (If I'm missing something, pls don't hesitate
to clarify)
+ Added SixDriver compatible HU ISO/WIN codepage files
for the reasons described above.
* harbour/include/hbapicdp.h
* harbour/source/rtl/cdpapi.c
* harbour/source/codepage/cpbg866.c
* harbour/source/codepage/cpbgiso.c
* harbour/source/codepage/cpbgwin.c
* harbour/source/codepage/cpcs852.c
* harbour/source/codepage/cpcsiso.c
* harbour/source/codepage/cpcskam.c
* harbour/source/codepage/cpcswin.c
* harbour/source/codepage/cpeldos.c
* harbour/source/codepage/cpelwin.c
* harbour/source/codepage/cpesdos.c
* harbour/source/codepage/cpesmwi.c
* harbour/source/codepage/cpeswin.c
* harbour/source/codepage/cpfrdos.c
* harbour/source/codepage/cpgedos.c
* harbour/source/codepage/cpgewin.c
* harbour/source/codepage/cphr1250.c
* harbour/source/codepage/cphr437.c
* harbour/source/codepage/cphr852.c
* harbour/source/codepage/cphu852.c
* harbour/source/codepage/cphu852s.c
* harbour/source/codepage/cphuiso.c
* harbour/source/codepage/cphuwin.c
* harbour/source/codepage/cpit437.c
* harbour/source/codepage/cpit850.c
* harbour/source/codepage/cpitisb.c
* harbour/source/codepage/cpitiso.c
* harbour/source/codepage/cpltwin.c
* harbour/source/codepage/cppl852.c
* harbour/source/codepage/cppliso.c
* harbour/source/codepage/cpplmaz.c
* harbour/source/codepage/cpplwin.c
* harbour/source/codepage/cppt850.c
* harbour/source/codepage/cpptiso.c
* harbour/source/codepage/cpru866.c
* harbour/source/codepage/cprukoi.c
* harbour/source/codepage/cpruwin.c
* harbour/source/codepage/cpsl437.c
* harbour/source/codepage/cpsl852.c
* harbour/source/codepage/cpsliso.c
* harbour/source/codepage/cpslwin.c
* harbour/source/codepage/cpsrwin.c
* harbour/source/codepage/cptrdos.c
* harbour/source/codepage/cptrwin.c
* harbour/source/codepage/cpua866.c
* harbour/source/codepage/cpuakoi.c
* harbour/source/codepage/cpuawin.c
* harbour/source/codepage/uc1250.c
* harbour/source/codepage/uc1251.c
* harbour/source/codepage/uc1253.c
* harbour/source/codepage/uc1254.c
* harbour/source/codepage/uc1257.c
* harbour/source/codepage/uc737.c
* harbour/source/codepage/uc850.c
* harbour/source/codepage/uc852.c
* harbour/source/codepage/uc857.c
* harbour/source/codepage/uc866.c
* harbour/source/codepage/uc88591b.c
* harbour/source/codepage/uc8859_1.c
* harbour/source/codepage/uc8859_2.c
* harbour/source/codepage/uc8859_5.c
* harbour/source/codepage/uckam.c
* harbour/source/codepage/uckoi8.c
* harbour/source/codepage/uckoi8u.c
* harbour/source/codepage/ucmaz.c
! #define namespace issue in public API header file
corrected:
CPID_* -> HB_CPID_*
UNITB_* -> HB_UNITB_*
* harbour/source/compiler/gencobj.c
! Fixed warning.
* harbour/common.mak
* updated for new files - please check
* harbour/harbour.spec
* added compiler library
* harbour/bin/pack_src.sh
* harbour/bin/hb-func.sh
* updated for new files and libraries
* harbour/config/w32/mingw32.cf
* harbour/config/w32/watcom.cf
* harbour/config/w32/xcc.cf
* added winsock libraries
* harbour/include/hbapicdp.h
* harbour/source/rtl/cdpapi.c
+ added hb_cdpicmp() - not case sensitive version of hb_cdpcmp()
* harbour/include/hbapiitm.h
* harbour/source/vm/itemapi.c
+ hb_itemStrICmp(), hb_itemCopyFromRef(), hb_itemMoveFromRef()
* harbour/include/hbapi.h
* harbour/include/hbcomp.h
* harbour/include/hbcompdf.h
* harbour/include/hbexpra.c
* harbour/include/hbexprb.c
* harbour/include/hbexprop.h
* harbour/include/hbmacro.h
* harbour/include/hbpcode.h
* harbour/include/hbvmpub.h
* harbour/include/hbxvm.h
* harbour/source/common/expropt1.c
* harbour/source/compiler/complex.c
* harbour/source/compiler/genc.c
* harbour/source/compiler/gencc.c
* harbour/source/compiler/gencli.c
* harbour/source/compiler/genhrb.c
* harbour/source/compiler/genobj32.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/hbmain.c
* harbour/source/compiler/hbopt.c
* harbour/source/compiler/hbpcode.c
* harbour/source/compiler/hbstripl.c
* harbour/source/macro/macro.y
* harbour/source/macro/macro.yyc
* harbour/source/macro/macro.yyh
* harbour/source/macro/macrolex.c
* harbour/source/vm/Makefile
* harbour/source/vm/arrays.c
* harbour/source/vm/asort.c
* harbour/source/vm/classes.c
* harbour/source/vm/eval.c
* harbour/source/vm/garbage.c
* harbour/source/vm/hvm.c
* harbour/source/vm/itemapi.c
* harbour/source/vm/macro.c
+ harbour/source/vm/hashes.c
+ harbour/source/vm/hashfunc.c
+ added hash items, f.e.:
local h1 := {=>}, h2 := { "a"=>1.234, "b"=>2.345 }
? h2[ "a" ], h2[ "b ]
+ added support for DYNAMIC function declaration - it allow to define
functions which are lately bound at runtime, f.e.:
/*** t01.prg ***/
dynamic func1
proc main()
local h:=__hrbload("t02.hrb")
? func1()
return
/*** t02.prg ***/
func func1
return "Hello!!!"
% use new FUNCALL structure to hold EXTERNAL and DYNAMIC functions,
it reduce memory usage, FUNCALL is much smaller then FUNCTION
% use symbol scope bits when possible instead of making some linear scan
+ added new enumarator message: __ENUMKEY - it allow to access
key value when hash item is base enumerator value, f.e.:
proc main()
local v, h:={"a"=>1.000,"b"=>2.000,"c"=>3.000}
heval( h, { |k,v,i| qout( k, v, i ) } ); ?
for each v in h
? v, "=>", v:__enumKey(), v:__enumValue(), v:__enumIndex(), ;
valtype(v:__enumBase())
v += 0.123
next
? ;heval( h, { |k,v,i| qout( k, v, i ) } )
return
+ added C level hb_hash*() functions
+ added support for full HASH item cloning and updated array cloning
to also clone nested hashes - please note that xHarbour does not do
that, in xHarbour ACLONE() clones _ONLY_ nested arrays and HCLONE()
_DOES_NOT_ clone _ANY_ nested items.
* harbour/include/hbextern.ch
+ added hash functions HB_H*()
* changed INET*() functions to HB_INET*()
+ added hash functions H*() and socket functions INET*() when
HB_COMPAT_XHB is set
* harbour/include/hbtypes.h
+ added missing HB_EXTERN_BEGIN / HB_EXTERN_END
* harbour/include/hbpp.h
* harbour/source/pp/ppcore.c
! added protection against automatic word concatenation in some cases
! fixed preprocessing expressions when match marker matches ';' token
* harbour/source/rtl/Makefile
+ harbour/source/rtl/itemseri.c
+ added functions for item serialization: HB_SERIALIZE() and
HB_DESERIALIZE() - these function are not binary compatible
with xHarbour functions with the same names but make very
similar job with the exception to serialization of codeblock
and object variables - Harbour does not allow to serialize
codeblocks and serialize objects as arrays.
In most cases these functions can replace the xHarbour ones
+ added HB_DESERIALBEGIN() and HB_DESERIALIZE() functions covered
by HB_COMPAT_XHB macro - this functions are only for compatibility
with existing xHarbour code, In Harbour HB_DESERIALBEGIN() is
dummy function which returns first parameter and HB_DESERIALNEXT()
is a simple wrapper to HB_DESERIALIZE() so it's not necessary to
use them.
* harbour/source/rtl/hbinet.c
* changed INET*() functions to HB_INET*() and enable them for default
build
+ added INET*() functions wrappers covered by HB_COMPAT_XHB macro
* harbour/source/rtl/hbrandom.c
+ added HB_RANDOMINT() - xHarbour compatible
* harbour/source/rtl/len.c
+ added support for HASHes
* harbour/source/rtl/valtype.c
+ added support for HASHes
+ added set of HB_IS*() functions - they are a little bit faster then
calling VALTYPE( v ) == <cVal>
- removed HB_ISBYREF() - this function cannot longer work, it was using
a Clipper incompatible anomalies in passing variables by reference I
fixed so it has to stop to work. If it will be realy necessary to
implement HB_ISBYREF() function then please inform me - it will have
to be done at compiler level or with some much deeper HVM stack
checking.
* harbour/source/vm/extend.c
! fixed hb_extIsArray() and hb_extIsObject() to work well with
parameters passed by reference.
Please note that now hb_extIsArray() return TRUE only for pure arrays
not object values.
* harbour/contrib/Makefile
+ harbour/contrib/tip/Changelog
+ harbour/contrib/tip/Makefile
+ harbour/contrib/tip/atokens.c
+ harbour/contrib/tip/base64x.c
+ harbour/contrib/tip/cgi.prg
+ harbour/contrib/tip/client.prg
+ harbour/contrib/tip/credent.prg
+ harbour/contrib/tip/cstr.prg
+ harbour/contrib/tip/encb64.prg
+ harbour/contrib/tip/encmthd.c
+ harbour/contrib/tip/encoder.prg
+ harbour/contrib/tip/encqp.prg
+ harbour/contrib/tip/encurl.prg
+ harbour/contrib/tip/ftpcln.prg
+ harbour/contrib/tip/hbhex2n.c
+ harbour/contrib/tip/httpcln.prg
+ harbour/contrib/tip/mail.prg
+ harbour/contrib/tip/popcln.prg
+ harbour/contrib/tip/smtpcln.prg
+ harbour/contrib/tip/tip.ch
+ harbour/contrib/tip/url.prg
+ harbour/contrib/tip/utils.c
+ added TIP library - code borrowed from xHarbour
Please test - a lot of above code is not well tested, also some peaces
were written over year ago for different things (f.e. serialization for
NETRDD) and now I collected them and committed.
The TIP library was not tested at all. It can be compiled but I cannot
say if it works - I hope that people familiar with it can make necessary
test and fixes.
It's also not the final version of low level HASH item code. I'm working
on more efficient structure which uses binary tries but I cannot say when
I'll finish it (maybe in this weekend or maybe in next year) so I committed
working version now even if I'm not happy with overall performance (BTW
not worser then in xHarbour)
* 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/source/vm/garbage.c
* minor cleanup
* harbour/source/rtl/cdpapi.c
* harbour/include/hbextern.ch
+ added HB_CDPLIST() - it returns array with all registered CODEPAGEs
* harbour/source/rtl/set.c
! fixed typo in _SET_DEFEXTENSIONS
* harbour/tests/testrpt.prg
! fixed syntax
! use lower name in report name to work properly on case sensitive
file systems
* harbour/bin/hb-func.sh
* added support -go[0-3] and other -g* switches to xhb* scripts
* harbour/include/hbapi.h
+ added ISSYMBOL() macro
* formatting
* harbour/include/hbapirdd.h
* changed definition of SUPERTABLE for optional dynamic overloading
this modification will not effect existing code
* harbour/include/hbrddfpt.h
* harbour/source/rdd/dbffpt/dbffpt1.c
* added support for NIL value in SIX3 FPT files
* harbour/include/hbcomp.h
* harbour/source/compiler/harbour.c
* harbour/source/compiler/genc.c
* harbour/source/compiler/gencli.c
* harbour/source/compiler/genhrb.c
* harbour/source/compiler/genjava.c
! message symbols are not function symbols - cleaned the HB_FS_MESSAGE
usage and fix the problem with registering static function in global
symbol table
* harbour/source/compiler/gencc.c
! fixed typo in compilation for platforms 64 bit LONG
* harbour/include/hbvmpub.h
* harbour/source/compiler/cmdcheck.c
* harbour/source/vm/asort.c
* harbour/source/vm/evalhb.c
* formatting
* harbour/source/rdd/dbcmd.c
* formatting and some minor clean-up
* harbour/source/rdd/workarea.c
* added default SYSNAME method
! fixed possible memory leak when APPEND failed in TRANSREC method
* harbour/source/rdd/hsx/hsx.c
! fixed using HS_ADD()/HS_REPLACE() without STRING/BLOCK expression
* harbour/source/rtl/cdpapi.c
* cleaned GCC4 warning
* harbour/source/rtl/do.c
* changed to keep parameter references in DO() function. Now it works
like IIF()/EVAL()
* harbour/source/vm/classes.c
* removed some definitions repared from hbapi.h
+ added support to passing function references as HB_IT_SYMBOL
* harbour/source/vm/dynlibhb.c
! fixed GPF in HB_LIBDO called with wrong parameter
* harbour/source/vm/hvm.c
! fixed hb_rddGetFieldValue() to not operate on unallocated stack area
it could cause unpredictable results when RDD had to access HVM, f.e.
for evaluation some pending relations. The whole code should be
carefully checked and to not operate on hb_stackTopItem() if other
functions are called to make the HVM fully reentrant.
+ added commented out support for passing HB_IT_SYMBOL as function
pointer
* formatting
* harbour/source/vm/itemapi.c
* return "S" for HB_IT_SYMBOL by hb_itemType()
* formatting
* harbour/source/lang/Makefile
- harbour/source/lang/msgen.c
* harbour/source/rtl/langapi.c
* moved EN lang definitions to core lang code so we always have at
least one lang module defined at sartup.
Modified after common group agreement - no one was against,
thanks to all for answers.
Please update non GNU make files and remove
harbour/source/lang/msgen.c file.
* harbour/source/rtl/cdpapi.c
* replaced CDP startup initialization with simple assignment
* harbour/source/rtl/gtpca/gtpca.c
* added #include <sys/time.h> for *nix platforms
* harbour/include/hbapicdp.h
* harbour/source/rtl/cdpapi.c
* added optional BOOL parameter to functions which translate to UTF8
to not translate control code characters
* harbour/source/rtl/gtsln/gtsln.c
* harbour/source/rtl/gtxwc/gtxwc.c
* update for new parameter in UTF8 functions
* harbour/contrib/htmllib/default.ch
* fixed few wrong definitions - Ryszard, the definitions where wrong
but Clipper PP seems to parse them.
* harbour/contrib/rdd_ads/ads1.c
* call AdsFlushFileBuffers() only when _SET_HARDCOMMIT is set (default)
* harbour/include/Makefile
+ harbour/include/hbgfx.ch
+ harbour/include/hbgfxdef.ch
+ added hbgfx.ch, hbgfxdef.ch and missing tbrowse.ch
* harbour/include/hbapigt.h
* harbour/include/hbgtcore.h
* harbour/source/rtl/gtapi.c
* harbour/source/rtl/hbgtcore.c
+ added hb_gtGfxPrimitive(), hb_gtGfxText() - it's a work in progress
now this functions works like in xHarbour allow to draw graphic
objects in GTs which can do that (GTALLEG, GTXWC) but I plan to
introduce some modifications in them.
+ harbour/tests/gfx.prg
+ added test program by Mauricio Abre (borrowed from xHarbour) which
illustrates GFX usage
* harbour/include/hbdefs.h
* harbour/source/compiler/genc.c
* harbour/source/compiler/harbour.c
* harbour/source/vm/hvm.c
* minor modification in some harbour func name and symbol scope
definitions - I'd like to keep them in one place for easier
manipulations in the future
* harbour/source/compiler/harbour.y
* harbour/source/pp/ppcore.c
* harbour/source/pp/pplib.c
* harbour/utils/hbpp/hbpp.c
* clean a little bit recent modification it should resolve the
problem with GPFs reported by users and some possible memory
leaks when preprocessing/compilation process is interrupted.
Ryszard I decided to always store copy of file name in open
files structure - it can be used by compiler, preprocessor,
PPLIB and HBPP and IMHO in all cases it should have valid
and always initialized in the same way members for easier
manipulation. In the future I'd like to clean the whole PP
usage. I will need to keep all compiler and PP static variables
in one structure pointed by pointer in thread local data or
passed to called functions for MT support.
* harbour/source/rtl/cdpapi.c
* set 0 at the end of destination string in hb_cdpStrnToUTF8()
* harbour/source/rtl/dateshb.c
! fixed possible GPF in CTOD when badly formated date is given
* harbour/source/rtl/gtxwc/gtxwc.c
* harbour/source/rtl/gtxwc/gtxwc.h
* changed the selection code - now both PRIMARY and CLIPBOARD
selections are set by Harbour. It should work with any programs
which uses any of them but I'd like to remove one of this selections
or give user a way to chose the preferred one. I can also add support
for automatic setting/clearing/pasting PRIMARY selection by GTXWC
with mouse and shift key. I'm waiting for opinions.
+ added basic support for GFX operations
+ harbour/source/rtl/gtalleg/Makefile
+ harbour/source/rtl/gtalleg/fixedth.sfc
+ harbour/source/rtl/gtalleg/gtalleg.c
+ harbour/source/rtl/gtalleg/ssf.c
+ harbour/source/rtl/gtalleg/ssf.h
+ added new GT by Mauricio Abre based on Allegro cross platform
graphic libraries.
Code borrowed from xHarbour and modified by my for new Harbour
GT API.
* harbour/bin/hb-func.sh
* added support for -L<librarypath> in xhbmk
* set the highest priority to user libraries specified by
-l<libname> linker option
* harbour/include/hbapicdp.h
* harbour/source/rtl/cdpapi.c
* added UTF8 related functions: hb_cdpUTF8StringLength(),
hb_cdpStringInUTF8Length(), hb_cdpUTF8ToStrn().
* Changed name of hb_cdpStrnToUTF() function to hb_cdpStrnToUTF8()
to avoid confusions with UTF16
* harbour/include/hberrors.h
* harbour/source/compiler/hbgenerr.c
* harbour/source/compiler/harbour.c
+ added to new errors (memory corruption and memory overflow) for
compiler level FM statistic.
* harbour/source/compiler/hbfix.c
! fixed stupid typo in copy and past which broke conditional jump
reduction
* harbour/include/hbgtcore.h
* harbour/source/rtl/hbgtcore.c
* harbour/include/hbgtinfo.ch
* harbour/source/rtl/gtdos/gtdos.c
* harbour/source/rtl/gtos2/gtos2.c
* harbour/source/rtl/gtwin/gtwin.c
* added new method to change screen buffer state (hot/cold/scroll)
and use them in some GTs.
* harbour/source/rtl/gx.c
* use screen dimensions as default values for SETMODE() not maxrow()/
maxcol()
* harbour/source/rtl/gtxwc/gtxwc.c
* harbour/source/rtl/gtxwc/gtxwc.h
* added support for clipboard
* added support for cursor shape - like in DOS/VGA
* harbour/source/rdd/workarea.c
* harbour/source/rdd/dbffpt/dbffpt1.c
* cleaned some redundant extern declarations
* xharbour/contrib/rdd_ads/ads1.c
* xharbour/contrib/rdd_ads/adsfunc.c
* removed some unnecessary #include ...
* harbour/source/rtl/str.c
* harbour/source/rtl/transfrm.c
* harbour/source/vm/itemapi.c
! fixed some small incompatibilities with Clipper in number to string
conversions
* harbour/harbour.spec
* harbour/make_bsd.sh
* harbour/make_drw.sh
* harbour/make_gnu.sh
* harbour/make_rpm.sh
* harbour/make_tgz.sh
* harbour/bin/hb-func.sh
* harbour/bin/pack_src.sh
* harbour/config/c.cf
* harbour/config/global.cf
* harbour/config/rules.cf
* harbour/config/darwin/gcc.cf
* harbour/config/darwin/global.cf
* harbour/config/dos/djgpp.cf
* harbour/config/dos/global.cf
* harbour/config/dos/install.cf
* harbour/config/dos/owatcom.cf
* harbour/config/hpux/gcc.cf
* harbour/config/hpux/global.cf
* harbour/config/linux/gcc.cf
* harbour/config/linux/global.cf
* harbour/config/linux/owatcom.cf
* harbour/config/sunos/gcc.cf
* harbour/config/w32/watcom.cf
* include ADSRDD by default in RPMs
* updated for new RPM which does not accept some old tags
* set -fPIC on 64bit platforms
+ added /etc/harbour/hb-charmap.def
* updated for new GT system and drivers
* harbour/contrib/dot/pp.prg
* harbour/contrib/dot/pp_harb.ch
* use _APMAIN as startup function
* cleaned direct access to item internals
* harbour/contrib/libct/Makefile
+ harbour/contrib/libct/ctwfunc.c
+ harbour/contrib/libct/ctwin.c
+ harbour/contrib/libct/ctwin.h
* added CT3 like Window System - it's a GT driver which inherits
from the existing one and adds CTW functionality
* harbour/contrib/libct/screen1.c
* updated for GTAPI modifications
* harbour/contrib/libnf/Makefile
* harbour/contrib/libnf/chdir.c
* harbour/contrib/libnf/mkdir.c
* harbour/contrib/libnf/rmdir.c
* use hb_fs*() API functions instead of calling DOS interrupts
Now NF dir functions works on all platforms - it will be nice
to update other functions too.
* harbour/contrib/libnf/dispc.c
* harbour/contrib/libnf/ftattr.c
* updated for GT API modifications, some of this code still depends
on EGA/VGA video buffer so will work only if user will force in GT
using it - it will be nice to rewrite them
* harbour/contrib/odbc/odbc.c
* harbour/contrib/ole/ole2.c
* casting and cleaning direct access to item internals
* harbour/contrib/rdd_ads/ads1.c
* harbour/contrib/rdd_ads/adsfunc.c
* harbour/contrib/rdd_ads/adsmgmnt.c
* synced with xHarbour
* harbour/include/Makefile
* added new header files
+ harbour/include/hbgtinfo.ch
+ added GTI_* defintions for hb_gtInfo() function.
This function works in similar way to dbInfo() in RDD.
The GTI_* definitions are taken from xHarbour "as is" and
they should be cleaned - not all functionality are supported
in Harbour and some others should be implemented in differ
way then in xHarbour.
+ harbour/include/hbgtcore.h
* harbour/include/hbapigt.h
* new GTAPI
hbgtcore.h file should not be included by user code
it's only for internal use in GT drivers
* HB_inkey_enum changed to int - this is bit field not enumerated type.
Many of C/C++ compilers forbid bit operations on enum types and
forcing it by casting which finally exceeds the enum range is defined
as bug because it may badly interacts with some compiler optimizations
* harbour/include/hbapi.h
* harbour/include/hbapicdp.h
* harbour/include/hbapierr.h
* harbour/include/hbapifs.h
* harbour/include/hbapiitm.h
* harbour/include/hbapilng.h
* harbour/include/hbapirdd.h
* harbour/include/hbdate.h
* harbour/include/hbdefs.h
* harbour/include/hbinit.h
* harbour/include/hbpcode.h
* harbour/include/hbrdddbf.h
* harbour/include/hbset.h
* harbour/include/hbstack.h
* harbour/include/hbvm.h
* harbour/include/hbvmopt.h
* harbour/include/hbvmpub.h
* separated internal and external API. Now the definitions for
internal HVM structures and functions are excluded by default
they could be enabled if user include hbvmopt.h before other
header files. Such operation should be done _ONLY_ by core
code - if 3-rd party developers make sth like that then it's
for their own risk and such code may stop to work with next
Harbour versions. Without hbvmopt.h the internal structures
like HB_ITEM, HB_DYNS, ... are mapped to 'void' so there is
no way to access their members so we can modify them in the
future without afford for 3-rd party code.
There is one small exception 'type' should be the first member
for HB_ITEM structure because I used a small ugly hack in
HB_IS_*() macros with castin PHB_ITEM to HB_TYPE* - it works
without speed overhead but if you think that it will be
better/cleaner to not use such tricks then it's enough to
change HB_ITEM_TYPE() definitions in hbvmpub.h - see note.
* cleared the usage of HB_EXPORT - to avoid problems with some C/C++
compilers we agreed that the only one common way of using HB_EXPORT
is adding it ad begining of declaration - please keep this convention
in the future.
+ added new functions:
hb_extIsObject(), hb_codeblockId(), hb_idleSleep(),
hb_fsGetOsHandle(),
hb_dynsymFindSymbol(), hb_dynsymGetSymbol(),
hb_dynsymSymbol(), hb_dynsymName(),
hb_dynsymMemvarHandle(), hb_dynsymAreaHandle(), hb_dynsymSetAreaHandle()
* changed hb_arrayClone() declaration to:
PHB_ITEM hb_arrayClone( PHB_ITEM pArray )
* changed hb_arrayFromParams() declaration to:
PHB_ITEM hb_arrayFromParams( int iLevel )
The previous version needed a pointer to stack relocatable area
so any stack resizing could cause GPF.
* harbour/include/inkey.ch
* added definitions for extended mouse keys/events and some key
combinations
* harbour/source/codepage/uc1250.c
* harbour/source/codepage/uc1251.c
* harbour/source/codepage/uc1253.c
* harbour/source/codepage/uc1257.c
* harbour/source/codepage/uc737.c
* harbour/source/codepage/uc850.c
* harbour/source/codepage/uc852.c
* harbour/source/codepage/uc866.c
* harbour/source/codepage/uc88591b.c
* harbour/source/codepage/uc8859_1.c
* harbour/source/codepage/uc8859_2.c
* harbour/source/codepage/uc8859_5.c
* harbour/source/codepage/uckoi8.c
* harbour/source/codepage/uckoi8u.c
* harbour/source/codepage/ucmaz.c
* updated unicode values for characters in rabge 1-31 to keep
DOS compatibility
* harbour/source/common/expropt1.c
* harbour/source/common/hbarch.c
* harbour/source/common/hbdate.c
* harbour/source/common/hbstr.c
* harbour/source/common/hbver.c
* keep HB_EXPORT at the beginning of function declaration
* harbour/include/hbpcode.h
* harbour/include/hbcomp.h
* harbour/source/compiler/harbour.c
* harbour/source/compiler/harbour.y
* harbour/source/compiler/hbfix.c
+ harbour/source/compiler/hbdead.c
* harbour/source/compiler/hbpcode.c
+ harbour/source/compiler/hbstripl.c
% rewritten jump optimization
! fixed some minor problems
* do not optimize jumps and local variable access by shorter
PCODE version and HB_P_NOOP when jump optimization is
disabled, this is a note I left in source code in few places:
/*
* optimizing jumps here by shorting them and setting HB_P_NOOPs
* only slow down the compilation process for three reasons:
* 1. When it's dummy jump to next instruction we need two passes
* in hb_compOptimizeJumps() to fully remove it
* 2. hb_compOptimizeJumps() also make jump shortcutting in each pass
* 3. When Jump Optimization is disabled (-kJ) then it cause slowness
* at runtime because we will have more HVM loops: first for the
* shorter jump and next for the HB_P_NOOP PCODE(s)
* [druzuz]
*/
+ added support for multi passes in jump/dead code elimination
(hb_compOptimizeJumps())
By default is set upto three passes.
Now hb_compOptimizeJumps() keeps all compiler internal data clean
on exist and can be called any times and does not change other
compiler's functions behaviors
+ added dummy jumps elimination
+ added optimization for:
IF .T.
IF .F.
WHILE .T.
WHILE .F.
etc.
* restored empty BEGIN/RECOVER sequence block elimination
if Jump Optimization is enabled then it marks the block
with HB_P_NOOPS else it cut the generated PCODE
+ added dead code eliminator (new functions hb_compCodeTraceMarkDead()/
hb_compPCodeTrace() - it works only when Jump Optimization is
not disabled)
As a result of the above we have smaller and faster PCODE.
I do not think that we will have meta code support in the reasonable
time and because I need some valid compiler data/structures like
updated table of all jumps for real C code (not PCODE in .c files)
generation then I decide to make some modifications and the above
is in practice a side effect of this work.
* harbour/source/rdd/dbcmd.c
* harbour/source/rdd/dbf1.c
* harbour/source/rdd/rddord.prg
* harbour/source/rdd/workarea.c
* harbour/source/rdd/dbfcdx/dbfcdx1.c
* harbour/source/rdd/dbffpt/dbffpt1.c
* harbour/source/rdd/dbfntx/dbfntx1.c
* harbour/source/rdd/nulsys/nulsys.c
* synced with my modifications in xHarbour
* updated for API modifications
* harbour/source/rtl/Makefile
+ added gtsys.c, gtfunc.c, hbgtcore.c
* harbour/source/rtl/accept.c
* harbour/source/rtl/alert.prg
* harbour/source/rtl/cdpapi.c
* harbour/source/rtl/console.c
* harbour/source/rtl/dates.c
* harbour/source/rtl/do.c
* harbour/source/rtl/errorapi.c
* harbour/source/rtl/errorsys.prg
* harbour/source/rtl/file.c
* harbour/source/rtl/fserror.c
* harbour/source/rtl/fstemp.c
* harbour/source/rtl/hbffind.c
* harbour/source/rtl/idle.c
* harbour/source/rtl/math.c
* harbour/source/rtl/oldclear.c
* harbour/source/rtl/strmatch.c
* harbour/source/rtl/strpeek.c
* harbour/source/rtl/valtype.c
* harbour/source/rtl/xsavescr.c
* updated for API modifications
* cleaned some compiler warnings
* harbour/source/rtl/filesys.c
+ added hb_fsGetOsHandle()
* updated for API modifications
* harbour/source/rtl/gt.c
* harbour/source/rtl/gtapi.c
* harbour/source/rtl/gtapiu.c
+ harbour/source/rtl/gtfunc.c
+ harbour/source/rtl/gtsys.c
+ harbour/source/rtl/hbgtcore.c
* harbour/source/rtl/inkey.c
* harbour/source/rtl/maxrow.c
* harbour/source/rtl/mouseapi.c
* harbour/source/rtl/setcolor.c
* harbour/source/rtl/setposbs.c
* harbour/source/rtl/shadow.c
* new GT API code
* harbour/source/rtl/saverest.c
* changed default behavior in SEVESCREEN/RESTSCREEN with parameters
out of screen range to be Clipper compatible. Added last logical
parameter to keep previous behavior for programs which begins to
use it.
* harbour/source/rtl/seconds.c
* include missing header file to fix C++ compilation
* make hb_secondsCPU global function
* harbour/source/rtl/set.c
* make HB_SET_TYPEAHEAD Clipper compatible
* harbour/source/rtl/gtcgi/Makefile
* harbour/source/rtl/gtcgi/gtcgi.c
- harbour/source/rtl/gtcgi/mousecgi.c
* rewritten for new GT API
some detail behaviors has been changed but I think the current
implementation is better for CGI programs output - please check
and fix me if necessary
* harbour/source/rtl/gtcrs/Makefile
- harbour/source/rtl/gtcrs/charmap.prg
+ harbour/source/rtl/gtcrs/chrmap.c
- harbour/source/rtl/gtcrs/debug.map
- harbour/source/rtl/gtcrs/eterm.map
* harbour/source/rtl/gtcrs/gtcrs.c
+ harbour/source/rtl/gtcrs/gtcrs.h
+ harbour/source/rtl/gtcrs/hb-charmap.def
- harbour/source/rtl/gtcrs/kbdcrs.c
- harbour/source/rtl/gtcrs/keymap.prg
- harbour/source/rtl/gtcrs/linux.map
- harbour/source/rtl/gtcrs/mousecrs.c
* new GTCRS based on my xHarbour and Flagship curses code
Please not that at runtime it looks for a file
/etc/harbour/hb-charmap.def where user can fully tune output
for his terminal. This file is included with proper path in
binaries created by make_rpm.sh and make_tgz.sh
Ryszard I've removed some of your extensions which are no longer
necessary and some other (keyboard sequence redefinition) should
be done in a little bit differ way. I would like to talk about it
when you test current code.
Added support for extended mouse keys (middle button and wheel).
* harbour/source/rtl/gtdos/Makefile
* harbour/source/rtl/gtdos/gtdos.c
- harbour/source/rtl/gtdos/mousedos.c
* rewritten for new GT API
Fixed some small problems, finished mouse code which for DJGPP
is fully Clipper compatible with real mouse SAVE/RESTORE code.
For other compilers it should be updated depending on memory
model and used DPMI driver (if any).
* harbour/source/rtl/gtos2/Makefile
* harbour/source/rtl/gtos2/gtos2.c
- harbour/source/rtl/gtos2/mouseos2.c
* rewritten for new GT API
Fixed some problems and finished the mouse code.
Please test it - I made all modifications without OS2 and
I was not able to make any test. I'm interesting in information
if it works and the speed difference - f.e. results from
tests/vidtest.prg run with previous and current version.
* harbour/source/rtl/gtpca/Makefile
* harbour/source/rtl/gtpca/gtpca.c
- harbour/source/rtl/gtpca/kbdos2.gcc
- harbour/source/rtl/gtpca/mousepca.c
* rewritten for new GT API
and finished so now it's full functional GT driver
I'm interesting in keyboard sequences used by PC-ANSI drivers
in DOS so it will be possible to implement also support for
extended keys input.
* harbour/source/rtl/gtsln/Makefile
* harbour/source/rtl/gtsln/gtsln.c
+ harbour/source/rtl/gtsln/gtsln.h
* harbour/source/rtl/gtsln/kbsln.c
* harbour/source/rtl/gtsln/keytrans.c
* harbour/source/rtl/gtsln/mousesln.c
* rewritten for new GT API basing on current xHarbour code
added support for slang 1.4x patched for UNICODE (Debian
patches used by most of current Linux distributions) and
slang 2.x - It's unicode ready, tries to detect terminal mode
(utf-8/iso) at startup and switch the internal logic to
iso/unicode mode. When compiled with slang 1.4x or 2.x
and terminal is in UTF-8 it can display all characters like
in DOS if only used font have them or good fall-back table is
loaded (f.e. the one created by QRCZAK)
Added support for extended mouse keys (middle button and wheel).
* harbour/source/rtl/gtstd/Makefile
* harbour/source/rtl/gtstd/gtstd.c
- harbour/source/rtl/gtstd/mousestd.c
* rewritten for new GT API
Now it can work as full screen GT driver redrawing the previous
screen contents from internal GT core buffers. I run with this
GT some of my programs and they work quite well ;-) of course
without colors.
* harbour/source/rtl/gtwin/Makefile
* harbour/source/rtl/gtwin/gtwin.c
- harbour/source/rtl/gtwin/mousewin.c
* updated for new GT API
+ harbour/source/rtl/gtxwc/Makefile
+ harbour/source/rtl/gtxwc/gtxwc.c
+ harbour/source/rtl/gtxwc/gtxwc.h
* new XWindow Console GT driver based on my and Giancarlo Niccolai
code form xHarbour - this GT can work in XWindow environment only
and create its own window for console output. It delays the
initialization to the moment when user try to display anything on
the screen so even without X Window system programs which uses this
GT can work as long as use only outstd/outerr output.
* harbour/source/vm/arrays.c
* updated for API modifications
+ added hb_arrayId(),
* changed hb_arrayClone() declaration to:
HB_EXPORT PHB_ITEM hb_arrayClone( PHB_ITEM pSrcArray )
* changed hb_arrayFromParams() declaration to:
PHB_ITEM hb_arrayFromParams( int iLevel )
* harbour/source/vm/arrayshb.c
* updated for API modifications
+ added new parameter iLevel to function HB_APARAMS()
* harbour/source/vm/classes.c
* harbour/source/vm/cmdarg.c
* harbour/source/vm/dynlibhb.c
* harbour/source/vm/estack.c
* harbour/source/vm/fm.c
* harbour/source/vm/garbage.c
* harbour/source/vm/maindll.c
* harbour/source/vm/maindllh.c
* harbour/source/vm/maindllp.c
* harbour/source/vm/mainstd.c
* harbour/source/vm/mainwin.c
* harbour/source/vm/memvars.c
* harbour/source/vm/pcount.c
* harbour/source/vm/proc.c
* updated for API modifications
* harbour/source/vm/codebloc.c
* updated for API modifications
+ added hb_codeblockId()
* harbour/source/vm/dynsym.c
* updated for API modifications
+ added new functions:
hb_dynsymFindSymbol(), hb_dynsymGetSymbol(),
hb_dynsymSymbol(), hb_dynsymName(),
hb_dynsymMemvarHandle(), hb_dynsymAreaHandle(), hb_dynsymSetAreaHandle()
* harbour/source/vm/eval.c
* updated for API modifications
* call hb_vmPushState()/hb_vmPopState() in hb_itemDo()/hb_itemDoC()
functions - it's necessary to make HVM reentrant safe.
* harbour/source/vm/extend.c
* updated for API modifications
+ added hb_extIsObject() similar to existing hb_extIsArray()
* harbour/source/vm/hvm.c
* updated for API modifications
+ added new functions: hb_vmPushState(), hb_vmPopState()
which save/restore HVM state (the top stack value which can be
processed and return item and maybe sth else in the future) making
HVM ready for reentrant.
* harbour/source/vm/itemapi.c
* updated for API modifications
+ added new function:
HB_EXPORT PHB_SYMB hb_itemGetSymbol( PHB_ITEM pItem );
! fixed bug in hb_itemPutNInt()
* harbour/tests/Makefile
* harbour/utils/hbdoc/Makefile
* harbour/utils/hbextern/Makefile
* harbour/utils/hbmake/Makefile
* harbour/utils/hbrun/Makefile
* harbour/utils/hbtest/Makefile
- removed badly added: dbfntx, dbfcdx, dbffpt, hbsix libraries.
what broke GNU make compilation for some compilers
This libraries should be included automatically when RDD lib
is included by *.cf files
Summary:
The whole patch (cvs diff -uN) is ~1.5MB length and I cannot describe
everything in details - sorry but it was too much modifications in
one commit so now just some of general notes.
The header files included as is does not have any information about
internal HVM structures and some functions. In practice only HB_SYMB
is public and it has to be public for .c files generated from .prg
so I force the fixed size of this structure (alignment independent)
by redefining some members to union with void * - it's a little bit
ugly trick but it effectively eliminates the problem of linking
binaries compiled with differ alignment C compiler switches.
The structures like HB_ITEM, HB_CODEBLOCK, HB_STACK, HB_DYNS are not
longer defined and pointers to the defined as void * - like in Clipper
the ITEM structure. It caused that I had to add some new functions
to make some operation still possible to implement. If I missed sth
and any of you will have a problem with your code then please inform
me about it and after a small discussion on Harbour developers list
we can decide if other functions should be added.
The internal API is still accessible. It's enough to include "hbvmopt.h"
file before other header files to enable it. Now only files in
source/vm directory include it.
The 3-rd party code which does not include hbvmopt.h (or tries to
set some internals macros) should be safe for future HVM modifications
and will work also with new binaries so 3-rd party library developers
should remember about it. If they won't then it's only their and
their clients problem not Harbour developers.
With this modifications I also create new GT model which is similar
to the one used by RDD with multi inheritance. It can be quite easy
extended to simultaneously load more then one GT subsystem (sth like
work areas in RDD) but I left it for the future when someone may
need it. hbapigt.h file now contains only information about public
functions and does not have any code which depends on current
internal implementation - it should be backword compatible as long
as somone did not try to use internal GT functions.
The internal GT system use hbgtcore.h file which should not be
included by 3-rd party code as long as someone will not make new
GT driver. The internal GT code is new so I expect that it will
be changed yet in the nearest future (I'm waiting for other developers
feedback) and in such case any 3-rd party GTs will have to be updated.
How it works:
The base GT driver (GTNUL) is fully functional GT driver which
makes all operations on memory buffer. After each screen write
Flush() method is called which check for dispcount() and if
it's 0 then call Refresh() method to update modified area by
Redraw() method. This method is dummy in GTNUL and external
output with this GT can be reached by outstd()/outerr() which
are now redirected to GT methods. A simple GT driver may overload
only Refresh() method to give full screen output.
Application can use only this GT driver and it seems to be very
good choice for GUI and background daemon/service programs.
This GT is loaded at startup then all other GTs can be loaded
later and inherit from the previously loaded GT drivers.
The new GT driver can overload as much method as wants/needs.
Now all GT operations are implemented as GT method so GT driver
can easy change their default behavior, f.e. it may fully overload
color parsing methods and use differ or extended to Clipper color
definitions.
I rewrote all existing GTs to work with new GT model.
OS2 users - please test GTOS2 which I was not able to test and
see the note in Redraw() method. If possible please make some
speed tests.
In fact now there is much more internal operations then it was
before but because they are done on memory only then current
code is much faster in this GT drivers which so far makes all
operations on real video area. I made some tests with GTNUL
and tests/vidtest.prg and the total overhead is minimal. Now
dipbegin()/dispend() in practice does not cost anything so it
gives additional speed improvement in application which extensively
use it.
More then one GT driver can be linked with final binaries and
chose on application startup by //GT<NAME> switch and/or environment
variable HB_GT=<name>
In the RTL is new GT function GTSYS() which works in similar way
to RDDSYS() in RDD subsystem and for linking default GT driver
for given platform. When RTL is compiled the default GT driver
is set to HB_GT_DEFAULT envvar and if not exist to HB_GT_LIB
envvar and if it also does not exist to hard coded platfom GTs
(see source/rtl/gtsys.c and source/rtl/Makefile for rules)
Adding to source code:
ANNOUNCE GTSYS
disable linking the default GT driver and:
REQUEST HB_GT_<name>
for linking given (<name>) GT driver, f.e.: REQUEST HB_GT_WIN
If you are working in SH environment (Linux and other *nixes users,
DJGPP bash, MinGW shell then it's possible to use -gt<name> switch
in hblnk / hbmk scripts to force linking GT drivers (it could be
repeated with different <name>) and the first one becomes the default
one. F.e.:
xhbmk -m -n -w -es2 -gtcrs -gtsln -gtstd -gtpca vidtest.prg
Usually the GT driver are loaded at HVM startup but it's possible
to load it later. I created new GT driver CTW which gives full
CT3 like Window system. The CT3 extended driver change the behavior
of some function in Clipper extended driver, f.e WRITECON() or
SETPOS() with parameters out of screen range. So I implemented it
CTW as RT GTs which is loaded when some of CTWIN function is used
(f.e. WOPEN()/WBOARD()) and inherits from any existing GT driver.
This is full CT3 WIN implementation with all detail behaviors I
found (with some CT3 bug fixes). It does not have any CT3 limitations
and can be used for any virtual screen/window size though I hardcoded
CT3 limitation for backword compatibility. If somone will want to
remove it then it will be enough to delete few lines from ctwin.c
file. I'm not CTWIN Clipper user so maybe I missed some side effects
in this driver and was not able to well test it so if you will find
any incompatibilities then please inform me.
THe default GT buffer uses 32bit character cell internally but
in savescreen/restscreen it uses VGA compatible two bytes character
cell. Some GT drivers may want to use differ character cell.
Now GTCRS and GTSLN use 32bit character cell by default. They
need additional information about character set (box/normal) to
properly display box characters. It is possible to force in this
GT drivers using Clipper compatible character cell by calling:
hb_gtInfo( GTI_COMPATBUFFER, <lCompat> ) -> <lPreviousSeting>
but in may cause that box drawing characters will be lost in
some countries after RESTSCREEN(). It will depend on used code
page.
HB_GTINFO() is new function which works in similar way to DBINFO()
in RDD. It allows to retrieve/change some of GT driver settings.
GTI_* actions are defined in hbgtinfo.ch - it has all GTI_*
definitions used in xHarbour. Now in Harbour only few of them
are implemented.
The new three .prg functions:
HB_SETKEYCP( <cTermCP> [,<cHostCP>] )
HB_SETDISPCP( <cTermCP> [,<cHostCP>] [,<lBoxChar>] )
HB_SETTERMCP( <cTermCP> [,<cHostCP>] [,<lBoxChar>] )
have been added. They set automatic input (HB_SETKEYCP)
and output (HB_SETDISPCP) (or both: HB_SETTERMCP) character
translation. They are also important for some GTs which
informing them about used internal code page for unicode
translation (GTXWC, GTSLN) and/or chosing proper character
set (standard/alternate) for letters and other (f.e. box
drawing characters) (GTCRS, GTSLN),
<cTermCP> is encoding used on external (terminal) side
<cHostCP> is encoding used internally, if not given then
current code page set HB_SETCODEPAGE() is used.
some of GTs which uses unicode output may
ignore <cTermCP>
<lBoxChar> is optional parameter which interacts with dispbox()
output disabling switching to alternate character
set in some GTs. It effectively causes that if internal
(host) code page contains some letters on the box char
positions then they will be shown also by box drawing
functions like dispbox() instead of CP437 characters.
In some cases it could be useful. By default lBoxChar
is not set and GTs which can switch between standard
and alternate character set (GTCRS, GTSLN) will try to
use alternate character set for box drawing functions.
Victor: I removed some of your functions. They can be very easy
implemented with hb_gt_GetChar()/hb_gt_PutChar() but I do not want to
make them part of documented external API because some GT drivers may
want to use absolutely differ color definitions and they will stop to
work so I do not want to make this functions documented external API.
Ryszard: Setting alternative debug keys does not longer work.
I like such possibilities but it should be implemented in differ
way to f.e. using HB_GTINFO interface to allow low level GT driver
extensions, f.e. in *nixes using CTRL+[A-Z] and SIGINT, SIGQUIT,
SIGTSTP signals for real asynchronous setting of debug/cancel flag
without keyboard polling from main HVM loop. I would like to discus
about such more general solution.
*** Please updated non GNU make files ***
+ config/dos/owatcom.cf
* added configuration file for OpenWatcom (renamed
from watcom.cf)
* config/dos/watcom.cf
* restored previous version so it correctly compiles
under WatcomC 10 - please use watcom.cf for WatcomC
and owatcom.cf for OpenWatcom
* makefile.bc
* makefile.nt
* makefile.vc
* hrbdll.bc
* source/codepage/Makefile
+ source/codepage/cdpsrwin.c
+ new file with Serbian codepage
* CVSROOT/avail
* removed reference to my local file
* ERRATA
* updated (removed reference to tmpname)
* doc/codestyl.txt
* updated with some coding guidelines adopted from PHP
(please fell free to discuss them ;-)
* doc/howtocvs.txt
* added description for commit on Linux
* include/hbapicdp.h
* source/codepage/cdpesdos.c
* restored previous versions
* include/hbcomp.h
* added <malloc.h> reference for WatcomC compiler
* include/hbexprc.c
* fixed warning reported by WatcomC
* source/vm/itemapi.c
* fixed infinite support for WatcomC
* source/rtl/cdpapi.c
* renamed global symbol s_cdpage into hb_cdp_page
* source/rtl/gtcrs/kbdcrs.c
* fixed reporting keystrokes with codes > 127
* source/compiler/gencli.c
* fixed warnings
* source/rtl/cdpapi.c
*fixed warnings (Can the author of the code check if
I correctly parenthesized multiple || and && conditions?)
* source/vm/classes.c
*fixed warning in gcc (commented out unused
static hb_clsScope function)
* source/rdd/dbfntx/dbfntx1.c
* source/rtl/fstemp.c
* fixed hb_fsCreateTemp() to use 'mkstemp' on Unix
* fixed sorting procedure to use hb_fsCreateTemp
wrapper function
* source/rtl/set.c
*hb_set.HB_SET_DIRSEPARATOR defaults to '/' on Unix