* utils/hbmk2/hbmk2.prg
+ hbmainstd/hbmainwin lib is now added for mingw family
to lib list also for static executables. It fixes the GPF
at startup with Equation Solution mingw64 build. I hope
it doesn't create any harm for other builds, it remains
to be tested.
% Disabled -fomit-frame-pointer for mingw64.
* utils/hbformat/Makefile
* utils/hbmk2/Makefile
* utils/hbi18n/Makefile
* utils/hbtest/Makefile
* utils/hbrun/Makefile
* config/win/mingw.mk
% "HB_MAIN" logic eliminated from local make files and moved
to mingw.mk only.
* src/vm/extrap.c
* src/vm/dynlibhb.c
* src/common/hbgete.c
* src/common/hbffind.c
* src/common/hbver.c
* src/rtl/filesys.c
* src/rtl/diskspac.c
* src/rtl/gtos2/gtos2.c
* src/rtl/cputime.c
* src/rtl/disksphb.c
* include/hbthread.h
* contrib/hbmzip/hbmzip.c
! Fixed to setup all OS/2 INCL_* constants and
to #include os2.h by themselves, and not to rely
on Harbour headers to do this job for them.
; TODO: Do the same for dos.h.
* doc/hdr_tpl.txt
- Deleted local changelog.
! Fixes to .prg function docs
+ Update copyright year to 2010.
+ Added fact that $SEEALSO$ should be comma separated.
+ Added .c function example (far from perfect)
* examples/hbdoc2/tmplates.prg
* doc/hdr_tpl.txt
+ Added $VERSION$ tag. (pls update HBIDE. We haven't finalized
the format yet, to it's little bit premature to create
new and new parsers/generators for it yet)
* include/hbdefs.h
! Fixed to not unconditionally include OS/2 headers with
an arbitrary selection of INCL_ macros.
Now OS/2 headers will only be included if legacy types
are requested (off by default), and no INCL_ macros
are defined. This latter change may affect 3rd party
code written for OS/2, so I'm marking it INCOMPATIBLE.
* contrib/hbqt/generator/hbqtgen.prg
* contrib/hbqt/hbqt.h
* Changed to #include hbapi.h from hbqt.h. It needs it,
so this is the clean way. Changed generator to leave
out hbapi.h from each source file and refer to hbqt.h
only. (untested)
+ Added logic to #include OS/2 headers with some INCL_
macros defined, to make QT on OS/2 happy. (copied them
from the dev. list)
; TODO: Regenerate HBQT sources.
* utils/hbtest/hbtest.prg
! Cleaned old problem reported by Chen. It seems like
a feature which was never finished, and it's not even
hugely needed, so I deleted it.
* config/global.mk
+ Will now provide HB_COMP_PATH_PUB value for os2-gcc, os2-gccomf
compilers. This value can be used to manually form ld.exe
command line.
(NOTE: This may be deleted in the future, when sorting
out line-length limit problems for these compilers.
* include/hbsetup.ch
* src/common/hbverdsp.c
- Deleted HB_COMPAT_XPP option. It's no longer used in Harbour.
From this point all Xbase++ compatibility functions and core
classes are implemented in 'xpp' contrib library (name
tentative). Add it to your lib list, if you need Xbase++
compatible functions. IOW HB_COMPAT_XPP build time option
got converted to a app link time option.
* src/rtl/isprint.c
- Deleted dirty Xbase++ extension of ISPRINTER(). Now it's
purely Clipper compatible in default build.
INCOMPATIBLE. For Xbase++ version, use XPP_ISPRINTER()
(or HB_ISPRINTER() which is the exact same).
* src/rtl/tobject.prg
* src/rtl/transfrm.c
* src/rtl/memoedit.prg
* include/memoedit.ch
* Replaced "#ifdef HB_COMPAT_XPP" with "#ifndef HB_CLP_STRICT".
Which means we've endorsed these extensions in Harbour,
and they are always enabled except in strict compatibility
builds.
* src/rdd/nulsys/nulsys.c
- Deleted HB_COMPAT_XPP guarded function.
* contrib/xhb/xhbver.prg
* Always return .T. for _HB_COMPAT_XPP in version info.
* include/box.ch
* contrib/xpp/xpp.ch
+ Added Xbase++ compatibility box.ch constants from core box.ch.
INCOMPATIBLE if you use B_THIN or B_FAT box style.
* utils/hbtest/hbtest.prg
* examples/hbdoc2/tmplates.prg
* examples/hbdoc2/hbdoc2.prg
- Deleted parts dealing with HB_COMPAT_XPP option.
* INSTALL
* Updated valgrind example.
* contrib/hbnetio/utils/netiosrv.hbp
* utils/hbformat/hbformat.hbp
* utils/hbmk2/hbmk2.hbp
* utils/hbi18n/hbi18n.hbp
* utils/hbtest/hbtest.hbp
* utils/hbrun/hbrun.hbp
* config/wce/msvcarm.mk
* config/win/msvc.mk
+ Added MSVC linker switches to enhance security by
enabling NX compatibility and ASLR.
Especially important for server apps like netiosrv and hbrun.
; TODO: Enable the same for MinGW.
; TOCHECK: Please test this with old MSVC versions and MSVCARM,
maybe we will need to disable them in some cases.
; QUESTION: I'm unsure of -fixed:no MSVC option. Do we need it
to increase security?
* config/wce/msvcarm.mk
+ Changed to use link.exe for linking instead of cl[arm].exe.
This now syncs it with rest of Harbour.
* harbour/src/vm/garbage.c
% small improvement in HB_GC_AUTO code
* harbour/include/hbdefs.h
! reverted the hack which casted file handles to unsigned values
I added two weeks ago - it was also converting FS_ERROR value
from -1 to 4294967295. Please remember that on some platforms
negative handles can exist and are valid. Only -1 indicates an
error.
* harbour/utils/hbtest/rt_file.prg
+ added regression test for FOPEN() FS_ERROR value
* harbour/contrib/hbwin/legacycd.c
* harbour/contrib/hbwin/legacyco.c
* added missing EOL at EOF
* harbour/utils/hbtest/rt_str.prg
* modified code which tries to replicate Clipper behavior with ULONG
values also in 64bit systems where ULONG is not 32bit integer
* config/global.cf
* config/rules.cf
* config/dos/watcom.cf
* config/win/watcom.cf
* config/os2/watcom.cf
% Using HB_PRGFLAGS instead of HB_FLAGSEXTRA.
% Using HB_CFLAGS and HB_PRGFLAGS instead of HB_CDBG.
% Using HB_CFLAGS instead of HB_CUNICODE.
% Moved all flags from HB_RULE to HB_FLAGS (except HB_USER_PRGFLAGS).
This only affects dos/watcom, more cmdlines will be put in HARBOURCMD.
* external/sqlite3/Makefile
* external/libhpdf/Makefile
* external/libpng/Makefile
* source/vm/maindllh/Makefile
* source/vm/maindllp/Makefile
* source/vm/vmmt/Makefile
* source/rtl/gtxwc/Makefile
* source/rtl/gtcrs/Makefile
* source/rtl/gttrm/Makefile
* source/rtl/gtsln/Makefile
* contrib/gtalleg/Makefile
* contrib/hbmysql/Makefile
* contrib/hbodbc/Makefile
* contrib/hbsqlit3/Makefile
* contrib/hbqt/Makefile
* contrib/hbfbird/Makefile
* contrib/hbcurl/hbcurls/Makefile
* contrib/hbcurl/Makefile
* contrib/gtqtc/Makefile
* contrib/rddsql/sddmy/Makefile
* contrib/rddsql/sddpg/Makefile
* contrib/rddsql/sddfb/Makefile
* contrib/rddsql/sddodbc/Makefile
* contrib/hbhpdf/Makefile
* contrib/hbpgsql/Makefile
* contrib/rddads/Makefile
* contrib/hbfimage/Makefile
* contrib/hbgd/Makefile
* contrib/hbtip/hbtipssl/Makefile
* contrib/hbssl/Makefile
! Using HB_CFLAGS/HB_PRGFLAGS to specify Makefile local
compiler settings instead of modifying HB_USER_*FLAGS.
This way the double defines are gone.
+ Included global.cf to all Makefiles which needs to modify
HB_CFLAGS/HB_PRGFLAGS. Probably we should move global.cf
inclusion to the top of all Makefiles as a convention.
Not terribly elegant, but solves a few problems and
more efficient.
% Changed ', -I$(d))' to ',-I$(d))' along the way. This avoids
wasting an extra space in command line.
; NOTE: It'd still be beneficial to find a way to get rid of
'descend' rule. It could make cmdlines cleaner/shorter
and whole build process simpler/faster. I didn't manage
so far.
* source/vm/Makefile
* Deleted 'HB_USER_CFLAGS := $(subst -DHB_MT_VM,,$(HB_USER_CFLAGS))'
(since it's no longer supported practice to modify user supplied flags)
I'm not sure if it's important enough to have. AFAIK there is no
reason users use HB_MT_VM define, it's not a public setting, so we
shouldn't go too much far in trying to protect against its presence.
If it's needed, we should add 'HB_CFLAGS += -DHB_ST_VM' and handle
HB_ST_VM as the reverse of HB_MT_VM inside the source.
* source/rdd/dbffpt/dbffpt1.c
* source/rdd/dbffpt/Makefile
* Optimizations are now disabled using #pragma for __XCC__ instead of
deleting them from HB_USER_CFLAGS. Please test, and see above on
modifying HB_USER_CFLAGS in our make files.
* bin/postinst.cmd
! Deleted double quote from target dir in xcopy commands.
Blind change.
* utils/hbtest/rt_main.ch
* utils/hbtest/hbtest.hbp
* utils/hbtest/Makefile
+ Changed to use #pragma to turn on line numbers instead of
using HB_USER_PRGFLAGS (or HB_PRGFLAGS). This way there is
no need for Makefile hack/tweaks and it works with all make methods
automatically.
* config/instsh.cf
! Partially restored a few things which were lost without comments
in prev OS/2 commit:
- Formatting
- '@' prefixes
- '-' prefixes
* config/bin.cf
+ Harbour binary core liblists are now formed centrally.
Four variations are generated:
HB_LIBS_ST_RDD
HB_LIBS_MT_RDD
HB_LIBS_ST_NORDD
HB_LIBS_MT_NORDD
Binaries can choose by using: 'LIBS = $(HB_LIBS_*)'.
Important to use '='.
This step also fixes potential problems with former liblists,
where it was easy to make a local mistakes and some libs which
needed more complicated logic, or which were just rarely used
simply weren't added. Now all liblists are guaranteed to have
proper order and content.
HB_GT_LIBS and HB_DB_DRIVERS are automatically added centrally,
so no need to add them manually in each compiler specific .cf.
* tests/Makefile
* tests/hbpptest/Makefile
* tests/multifnc/Makefile
* utils/hbformat/Makefile
* utils/hbmk2/Makefile
* utils/hbtest/Makefile
* utils/hbi18n/Makefile
* utils/hbrun/Makefile
% Using above HB_LIBS_* macros.
; The only few places which I didn't thouch is non-Harbour
executables (harbour exe and hbpp exe).
* config/bsd/gcc.cf
* config/wce/msvcarm.cf
* config/wce/mingwarm.cf
* config/wce/poccarm.cf
* config/hpux/gcc.cf
* config/darwin/gcc.cf
* config/dos/watcom.cf
* config/dos/djgpp.cf
* config/win/watcom.cf
* config/win/icc.cf
* config/win/cygwin.cf
* config/win/msvc.cf
* config/win/xcc.cf
* config/win/mingw.cf
* config/win/pocc.cf
* config/win/bcc.cf
* config/linux/watcom.cf
* config/linux/gcc.cf
* config/linux/icc.cf
* config/linux/sunpro.cf
* config/os2/watcom.cf
* config/os2/gcc.cf
* config/sunos/gcc.cf
* config/sunos/sunpro.cf
% Deleted local logic to merge HB_GT_LIBS and HB_DB_DRIVERS
into LIBS.
* utils/hbmk2/hbmk2.hbp
* utils/hbrun/hbrun.hbp
! Extra libspecs are still needed for some compilers.
I've readded them until better solution is found.
* harbour/source/macro/macro.y
* harbour/source/macro/macro.yyc
* harbour/source/compiler/harbour.y
* harbour/source/compiler/harbour.yyc
% reduced INASSING definition - thanks to Xavi for information
* harbour/source/compiler/hbopt.c
! fixed stupid bug in logical expression optimization - thanks to Randy
for self contain example
* harbour/include/hbapi.h
* harbour/include/hbmacro.h
* harbour/include/hbexprb.c
* harbour/source/vm/macro.c
* harbour/source/vm/hvm.c
* harbour/source/macro/macro.y
* harbour/source/macro/macro.yyc
+ added direct support for pushing references to macro expressions.
It resolves the problem with Clipper compatibility (thanks to Alex
for information and example) in code like:
m->var := {0}
&("var[1]") += 10
and also many other things, f.e. now Harbour can cleanly compile
and execute this code:
proc main
local s
m->o := errorNew()
s:="o:tries"
? m->o:tries
? &s
? &(s+"+=2")
? m->o:tries
? &(s+":=3")
? m->o:tries
?
&s := 4
? m->o:tries
&s -= 2
? m->o:tries
&s++
? m->o:tries
?
s := "o"
m->o := 1
? &s
&s := &s + 4
? &s
? &s += 5
? --&s
?
s := "o[2]"
m->o := { 1, 2 }
? &s
&s := &s + 4
? &s
? &s += 5
? --&s
return
* harbour/utils/hbtest/Makefile
* force hbtest compilation with line numbers - information about line
numbers is important part of this test.
* tests/speedtst.prg
! Fixed missing hb_progname() for non-Harbour compilers.
* include/hbextern.ch
+ Added time related new functions.
* utils/hbmk2/hbmk2.prg
+ Added -runflag: option to pass flags to target executable.
+ Started -inc (incremental link) support. It's very early
stage, don't expect it to work yet and please don't report
any problems with this feature yet.
* source/vm/asort.c
! Fixed to return Clipper compatible results when non-logical
non-numeric value is returned from ASORT() codeblock.
* utils/hbtest/rt_array.prg
* Cleaned ASORT() tests when sorting block returns constant value.
Now Clipper results aren't bent anymore, instead I've added
different expected results for Harbour and Clipper. The
difference is due to different sorting algorithms used,
here the point is to get similar *pattern* for different
invalid values.
* source/rtl/philes.c
% HB_FGETDATETIME(): Removed double call to hb_stortdt().
* contrib/hbqt/tests/hbqt.hbp
* Removed extra line at EOL.
* contrib/gtqtc/tests/hbqt.hbp
! Removed environment dependent 'libspath=' line.
Please don't add such path to Harbour SVN, since these
can differ from system to system and is also non-portable.
The correct name of the directive is: 'libpaths='.
* contrib/gtqtc/Makefile
% Removed double SVN ID.
This file needs to be updated according to hbqt latest
Makefile portability changes.
* contrib/rddads/ads1.c
* Minor formatting.
* bin/hb-mkdyn.bat
* Cleaned tool outputs.
+ Added hbmaindllh lib to included liblist.
(dunno what this serves, but we had it in non-GNU make)
Do we need this at all?
+ Added support for msvc64 dll name.
* Some tweak to owatcom, but it's just guessing, it still
doesn't work.
+ Added generating hbrun-dll executable.
* source/vm/hvm.c
* source/vm/mainstd.c
* Random tweak for owatcom/win dll support without success.
Best result so far is:
"Unrecoverable error 9012: Can't locate the starting procedure: 'MAIN'"
* source/vm/Makefile
+ Added mainddllp generation for msvc, msvc64, bcc32, owatcom.
* source/vm/maindllp.c
+ Added msvc64 and msvcia64 .dll names.
* source/vm/extrap.c
* Minor tweak to use alternate (documented) CPU detection macro.
* utils/hbmk2/hbmk2.prg
+ Added msvc64 .dll name.
* Removed automatic addition of hbcommon lib for shared
mode for win compilers.
* utils/hbtest/hbtest.hbm
* utils/hbrun/hbrun.hbm
+ Added make files.
* config/lib.cf
* config/bin.cf
+ Added -n to Harbour flags to bin.cf.
+ Added -n1 to Harbour flags to lib.cf.
; TOFIX: The former works, the latter doesn't.
Could someone please help why is this
happening?
* utils/hbmk2/hbmk2.prg
- Removed -n from default Harbour switches.
; TODO: Add prgflags=-n to all .hbp files.
; TODO: Add -n to all .hbm files.
; TODO: Add .hbp file to dirs where there are .prgs
needing -n flag.
+ bin/hb-mkdll.bat
+ Added .dll creation for GNU-make. Not yet enabled,
only MSVC supported, and by the nature of the
wonderful world of Microsoft, whole Harbour needs
to be compiled with HB_USER_CFLAGS=-DHB_DYNLIB to
make this work. -DHB_DYNLIB has some drawbacks
though: export table will be generated for all
executables made from these .libs, .exp/.lib will
also be generated for all executables.
; TODO: Solve to compile Harbour lib .prgs using
-n1 switch. (needed for .dll, and this
one has only befenefits for other scenarios)
; TODO: Add hb-mkdll.bat to postinst.bat.
; TODO: Add BCC support, if possible.
; TODO: Rename hb-mkslib.sh to 8.3 name and sync
name with the .bat version (not necessarily
mkdll, but something short.)
* bin/hb-func.sh
! Added system libs for optional components included
in the harbour dynlib. I plan to make some more
changes here, but this should fix missing system
libs with shared option enabled in hbmk2.
* contrib/examples/dbu/dbu.hbm
* contrib/examples/rl/rl.hbm
+ Added -n.
* utils/hbdoc/Makefile
* utils/hbmk2/Makefile
* utils/hbtest/Makefile
* utils/hbi18n/Makefile
* utils/hbrun/Makefile
- Removed explicit -gc0 -n override.
Should now be set automatically for all binaries.
* harbour/contrib/hbmysql/tmysql.prg
* harbour/contrib/hbpgsql/pgrdd.prg
* harbour/contrib/hbpgsql/tpostgre.prg
! fixed unused variables and meaningless assignment detected by new
compiler extension - many thanks to Mindaugas for it.
* harbour/include/hbsetup.h
+ added macros for some function attributes which can be used in
the future for optimizations
* harbour/source/rtl/filesys.c
* formatting
* harbour/source/rtl/hbtoken.c
* changed the behavior of " " token delimiter - now it works as
any other tokens. The old behavior can be still reach using empty
string "" as token delimiter. "" is not default token.
* harbour/utils/hbtest/hbtest.prg
* change error object to text conversion in hbtest so now it detects also
differences which were ignored by previous version, f.e. OPERATION
wrongly used instead of FILENAME or wrongly set TRIES flag.
* harbour/utils/hbtest/hbtest.prg
* harbour/utils/hbtest/rt_trans.prg
* harbour/utils/hbtest/rt_math.prg
* harbour/utils/hbtest/rt_hvm.prg
* harbour/utils/hbtest/rt_misc.prg
* harbour/utils/hbtest/rt_hvma.prg
* harbour/utils/hbtest/rt_class.prg
* harbour/utils/hbtest/rt_str.prg
* harbour/utils/hbtest/rt_stra.prg
* harbour/utils/hbtest/rt_date.prg
* harbour/utils/hbtest/rt_array.prg
* updated for extended error messages, tested with Harbour, Cl52/53
* harbour/include/hbapierr.h
* harbour/source/rtl/errorapi.c
+ added hb_errRT_FileError() used in file errors
! fixed TRIES counter updating when RETRY flag is set - it should
be done before calling error block not after - detected by new
hbtest error messages
; TOFIX: in practice all errors with RETRY flag generated by
other hb_errRT_*() functions have to be fixed because
new error object is created each time and informations
from previous one are lost, f.e. TRIES counter or CARGO
value set by user. They should be reimplemented in similar
way to hb_errRT_FileError()
* harbour/source/vm/memvars.c
* harbour/source/rtl/copyfile.c
* harbour/source/vm/set.c
! fixed wrong error messages detected by new hbtest in _SET_PRINTFILE,
_SET_ALTFILE and _SET_EXTRAFILE
; TOCHECK - Does CA-Cl*pper respect _SET_DEFAULT in above SETs?
* source/vm/set.c
! _SET_EVENTMASK RTE removed to be Clipper compatible.
! _SET_VIDEOMODE RTE removed to be Clipper compatible.
! _SET_MBLOCKSIZE default value set to 64 (was 0) to be Clipper compatible.
(pls correct me if this was intentionally wrong)
* utils/hbtest/rt_misc.prg
+ Added one C5.2 SET()s for two simple tests.
+ Added all C5.3 SET()s for two simple tests each.
; NOFIX: _SET_VIDEOMODE has the type wrong.
; NOTE: It wouldn't be a bad idea to add some more comprehensive
tests for SET()s.
* include/hbextern.ch
* common.mak
* source/rtl/Makefile
+ source/rtl/hbi18n.c
+ Added basic/low level i18n functions:
__I18N_SAVE( cFileName | nHandle, aSortedTable [, cComment ] ) => lSuccess
__I18N_LOAD( cFileName | nHandle ) => trs
__I18N_GETTEXT( @cText, trs ) => NIL
; NOTE: These were originally based on Giancarlo Niccolai's work in xhb,
but everything was completely reworked, fixed, internals removed,
made portable, lighter, shorter and probably quicker. The used file
format is incompatible, slightly smaller and portable.
; NOTE: The internal format of 'trs' (loaded translation) is also
different. For minimal memory/speed overhead, I've choosen a one
dimensional array, as opposed to the original two dimensional
(like the input aSortedTable array).
; TODO: Higher level functions to handle selecting a default
language, loading files automatically, possibly caching
multiple loaded language translations in memory and providing
a high level HB_I18N_GETTEXT() function. We may also readd
a low-level function to create 'trs' from a memory object
instead of loading it from the disk. We should in any case make
the higher level the lightest and less app specific as possible.
* include/hbver.ch
* source/rtl/version.c
* utils/hbtest/rt_str.prg
* ChangeLog
! Fixed returning bit width.
* Reworked hb_version() parameter values as follows:
(also fixed some differences between docs here in the
previous entry and actual code)
HB_VERSION_HARBOUR (was: HB_V_HARBOUR )
HB_VERSION_COMPILER (was: HB_V_COMPILER )
HB_VERSION_MAJOR (was: HB_V_MAJOR )
HB_VERSION_MINOR (was: HB_V_MINOR )
HB_VERSION_MICRO (was: HB_V_REV )
HB_VERSION_STATUS (was: HB_V_STATUS )
HB_VERSION_REVISION (was: HB_V_COUNT )
HB_VERSION_BLD_DATE_STR (was: HB_V_DATE_TIME )
HB_VERSION_BLD_DATE (was: HB_V_DATE )
HB_VERSION_BLD_TIME (was: HB_V_TIME )
HB_VERSION_PCODE_VER (was: HB_V_PCODE )
HB_VERSION_PCODE_VER_STR (was: HB_V_PCODE_STR )
HB_VERSION_CHANGELOG_LAST (was: HB_V_CHANGELOG_LAST )
HB_VERSION_CHANGELOG_REV (was: HB_V_CHANGELOG_REV )
HB_VERSION_FLAG_PRG (was: HB_V_FLAG_HARBOUR )
HB_VERSION_FLAG_C (was: HB_V_FLAG_C )
HB_VERSION_FLAG_LINKER (was: HB_V_FLAG_LINKER )
HB_VERSION_BITWIDTH (was: HB_V_BITWIDTH )
HB_VERSION_ENDIANNESS (was: HB_V_ENDIANNESS )
This function makes deprecated following functions:
- HB_COMPILER() => hb_version( HB_VERSION_COMPILER )
- HB_PCODEVER() => hb_version( HB_VERSION_PCODE_VER_STR )
- HB_BUILDDATE() => hb_version( HB_VERSION_BLD_DATE_STR )
and macros:
- __ARCH16BIT__
- __ARCH32BIT__
- __ARCH64BIT__
- __LITTLE_ENDIAN__
- __BIG_ENDIAN__
- __PDP_ENDIAN__
- HB_VER_SVNID
- HB_VER_CHLID
- HB_VER_LENTRY
- HB_VER_C_USR
- HB_VER_L_USR
- HB_VER_PRG_USR
; TOFIX: Some term anomalies regarding 'REVISION'.
* source/vm/runner.c
* Minor formatting and added "s_" prefix to static var.
* harbour/source/vm/thread.c
+ added small description for hb_threadOnce() .prg function
* harbour/include/hbthread.h
! do not set TLS in POCC and XCC builds when _MSC_VER macro is set
This compilers also have this macro but dllspec( thread) does
not work for them (at least in version 4.50.15)
* harbour/utils/hbtest/rt_hvm.prg
+ added few tests which exploit by DMC bug. Be careful with
this compiler. In some cases it gives buggy final code, f.e.
try this:
#include <stdio.h>
typedef struct
{
double dd;
long long int ll;
} UN;
const char * cmp( UN * pU )
{
return pU->dd >= pU->ll ? "OK" : "ERRROR";
}
int main( void )
{
UN u = { 10.50, 10 };
printf( "%s\n", cmp( &u ) );
return 0;
}
The same bug can be exploited also by final Harbour binaries
compiled by DMC in code like:
? iif( 10.50 >= 10, "OK", "ERROR" )
I used DMC 8.42n. As long as such things will not be fixed by
DMC developers this compiler is not supported by Harbour and
reported problems with DMC Harbour builds will have to be
ignored by us.
* harbour/utils/hbtest/rt_class.prg
! fixed description message
* harbour/common.mak
* harbour/utils/hbtest/Makefile
* harbour/utils/hbtest/hbtest.prg
+ harbour/utils/hbtest/rt_mt.prg
+ added simple MT test for fast checking MT builds
NOTE: DMC builds crashes with and without direct TLS access
If possible it has to be fixed. Now MT mode is not supported
for this compiler.
* bin/bld.bat
* Some changes to make it more up-to-date.
* utils/hbtest/hbtest.prg
* utils/hbtest/rt_array.prg
+ Added comment to 'TAEVSM' test case saying this is
a CA-Cl*pper bug.
+ Added two additional tests doing resizes in ASORT()
blocks. They fail very badly in Harbour. (TOFIX)
; Made my indenting of ChangeLog entries compatible with
everyone else's.
* utils/hbtest/rt_array.prg
+ Added failing test case of doing AEval()
and resizing the evaluated array in the
eval codeblock.
* utils/hbdoc/ft_funcs.prg
* utils/hbdoc/hbdoc.prg
* utils/hbmake/ft_funcs.prg
* utils/hbmake/hbmutils.prg
! Two EOL handling fixes applied.
Thanks to Bill Robertson.
; Please test.
* contrib/xhb/Makefile
* contrib/xhb/common.mak
+ contrib/xhb/arrayblk.prg
+ Added HB_ARRAYBLOCK()
* contrib/make_gcc_all.sh
+ Added darwin autodetection.
* contrib/Makefile
+ Added HB_CONTRIB_ADDONS envvar which enables building
local custom contribs stored in the contrib dir.
A separate dir may be better, but we will see.
* utils/hbtest/hbtest.prg
* Changed test .dbf filename casing to lowercase.
+ tests/rddtest
+ tests/rddtest/rddmktst.prg
+ tests/rddtest/adscl52.prg
+ tests/rddtest/adscl53.prg
+ tests/rddtest/ntxcl52.prg
+ tests/rddtest/ntxcl53.prg
+ tests/rddtest/cdxcl52.prg
+ tests/rddtest/rddtst.prg
+ tests/rddtest/make_c52.bat
+ tests/rddtest/cdxcl53.prg
+ tests/rddtest/make_c53.bat
+ Added RDD tests from xhb.
* harbour/contrib/hbw32/dllcall.c
* minor cleanup in return values
* harbour/contrib/hbole/ole2.c
* cleaned casting in UNICODE conversions
* harbour/source/common/expropt2.c
* replicate CA-Cl*pper compile time optimization bugs:
"" $ <literString> => .T.
AT( "", <literString> ) => 1
CHR( 256 ) => ""
only when Harbour extensions (-kh) are not enabled, f.e.
in strict Clipper compatibility mode (-kc)
* harbour/utils/hbtest/rt_hvma.prg
* harbour/utils/hbtest/rt_str.prg
* updated to test Clipper and Harbour compile time modes in
the above situations
* harbour/common.mak
* harbour/source/rtl/Makefile
- harbour/source/rtl/strings.c
* harbour/source/common/hbstr.c
* moved hb_strEmpty() from RTL to COMMON library
* harbour/include/hbexprb.c
* harbour/include/hbexprop.h
* harbour/source/common/expropt2.c
+ added compile time optimization for EMPTY() function
; removed 'TODO: empty optimization' note
* harbour/source/rtl/itemseri.c
% compress trailing spaces during string item serialization
* harbour/include/hbapi.h
* harbour/source/vm/hashes.c
+ added hb_hashAddNew() - works like hb_hashAdd() but it adds item
only if new key is used
* harbour/source/vm/hvm.c
* use hb_hashAddNew() instead of hb_hashAdd() for HB_P_HASHGEN
I cannot revert the order of hash item during compilation because
it will also change the order of user expression evaluation.