Project hosted by SourceForge.net
 
 
xHarbour.com
 
Open Source Extended Clipper Language

xHarbour News

2005-06-09

xHarbour BETA-1.5 for the different platforms are available for download from the download page now.

Here are some of the fixes, and new features offered by Beta-1.5:

xHarbour Core compiler
  • Increased HB_PCODE_VER to 7


  • Fix on hb_stripOutComments() -> pointer not moved after finding '/*' instance


  • Fixed hb_compAutoOpen() to process command line after initializing PP


  • Dramatically speed improvement for TRY/CATCH/END and exceptions handling


  • Additional flags on SAVE/RESTORE FROM *.mem; Possible commands:

    • save to mymem all like mylongvariable* extended
    • save all except mylongvariable2 to mymem extended
    • save to mymem all except mylongvariable2 extended
    • save to mymem all extended + restore from mymem additive extended
    • restore from mymem extended "EXTENDED" flags works on xHarbour flavor ie. memvar names with more than 10 chars length ie. MYVARIABLE_MORE_THAN_10 Default length is HB_SYMBOL_NAME_LEN (64 by default) Variable saved with "EXTENDED" must be restore with "EXTENDED" too

  • Optimized hb_stricmp()


  • Fixed possible overflow in hb_strncpyUpperTrim(), hb_strncpyTrim()


  • Added support in classes for explictly calling ::__Destructor() and ::__OnError()
  • Added parser support for hashes syntax


  • Fix bug in hb_compExprReduceDiv() in this situation: DOUBLE / 0 or LONG / 0.0


  • Fixed generation for pushing [...] when is a FIELD


  • Fixed generation of M[EMVAR]->Samovar[...] := ...


  • Enable INIT/EXIT PROCEDURE written in C dump


  • Fix compilation error in a fragment like:

    PROCEDURE MAIN()
    RETURN

    #PRAGMA BEGINDUMP
    #include "hbapi.h"
    #ifdef __INCLUDE_THIS__
    HB_FUNC( FOO ) {;}
    #endif
    #PRAGMA ENDDUMP


  • Fixed rules for CLASS[]METHOD


  • Added missing Hash functions in hbextern.ch
xHarbour Virtual Machine (VM)
  • Added support for optional 4th argument to HB_aTokens()


  • Added support for new HB_P_TRYBEGIN, HB_P_TRYEND, HB_P_TRYRECOVER


  • Added HB_FUNC( THROW )


  • Added logic to use hb_vmRequestBreak( pError ) if in TRY block


  • Function RASCAN (Reverse AScan) added


  • Generate a R/T error if ErrorBlock() is called within a TRY/END code or use hb_vm_BreakBlock if HB_USE_BREAKBLOCK is defined


  • Fixed bug: ASCAN({"A","BC"},"B") now works


  • Fixed bug: RASCAN({"A","BC","D"},"B") now works. + Added sixth parameter: lAllowChar, for support single-byte/numeric conversion (default .F., as Clipper behavior)


  • Added PHB_ITEM pPrevErrBlock to struct _HB_SEQUENCE


  • Added logic to set/restore ErrorBlock in TRY/END


  • Added PHB_ITEM hb_errorBlock( PHB_ITEM pNewErrorBlock )


  • Reverted ErrorBlock() to NOT care about hb_vm_iTries


  • Fixed initialization order. We cannot run any unknown .prg code before hb_vmDoInitStatics() because if it uses static variables then it will GPF. We need some error system enabled when hb_vmDoInitStatics() is executed. So we added the function hb_vmDoInitError() which set it


  • Restored previous version of s_uiActionRequest checking in main hvm look


  • Added SIXCDXINIT, RMDBFCDXINIT and ADSINIT to rdd initialization


  • Added __ErrorBlock()


  • Added __MinimalErrorHandler()


  • hb_vmDoInitError() now calls __Errorlock() instead of ErrorSys() This provides minimal handling for STATIC initialization errors. After static Initialization ClipInit() is called to set normal ErrorSys. v Added support for FINALLY syntax:

    TRY
    ...
    [THROW( )]
    ...
    [CATCH []] ... [FINALLY]
    ...
    END


  • Fixed hb_itemPutNInt() and hb_itemPutNIntLen() to work like other hb_itemPut*() functions - it should return new item when NULL was passed as first parameter. This also fix GPF in SKIPEVAL in DBFCDX


  • Fixed GPF trap in hb_vmPlus() (support for strings)


  • Corrected HB_P_ADDINT support for strings to retain string context


  • Fixed background tasks logic to preserve value of HB_VM_STACK


  • RT error message on error 1340/1341/600 to conform with Clipper ones


  • Fixed, optimized and simplified HB_FUNC( HB_EXECFROMARRAY ) and hb_execFromArray()


  • Added macro parser support for extended strings (E"..." )


  • Added macro parser support for hashes syntax


  • Added macro parser support for IN, HAS, and LIKE operators


  • Added macro support for BIT OPERATORS
xHarbour Run Time Library (RTL)
  • file_read() is a public function now


  • Fix bugs in __DBDELIM when appending from large textfile due to accumulation of array which may exceed memory buffer. This is a temporary solution until RDDSDF is implemented


  • Added prg level AppendToDb()


  • Corrected call to HB_aTokens() to pass 4th argument as .T. so only "" are processed as strings


  • Fixed HB_Serialize( ALIAS->MEMO_FIELD )


  • Cover the ASM and inp()/out() instructions for TONE by HB_ARCH_32BIT


  • Added missing AllTrim() before processing each value in dbdelim.prg


  • Added error handler to Ttable.prg to allow using table fields as class member


  • CURDIR[X]() now respects parameter eg. CURDIR("D:")


  • Fixed and optimized hb_strnicmp()


  • Corrected 0 to MB_PRECOMPOSED in call to MultiByteToWideChar() in Win32OLE


  • Fix problem in Teditor.prg with long strings that do not have a space in them and word wrap is on. A space was being added by the line parsing


  • Fix problem in Teditor.prg with string not ending in a eol. The string returned would have an extra line


  • Removed strtran tabs=>space(1), nTabSize should handle this if needed in memoedit


  • Changed 0 to LOCALE_USER_DEFAULT on Invoke() calls in Win32OLE


  • Fixed problem on getprevalidate method in tgetlist, that was forcing the display of get object, when oget:control is valid


  • Fix display issue in Tbrowse when ::colPos is set when ::leftvisible>::nFrozenCols


  • Fix text2array() support for trailing spaces or linew with many spaces in TEditor


  • Fix getparapraph() does not need to add a space to the line in TEditor. On lines with no spaces this would cause "corruption" of the text


  • We found that Clipper highlights the current item AFTER calling the user defined function


  • Also we found that Clipper calls the UDF in the beginning ONLY if the UDF returns a value different than 0


  • Fixed bug in handling @( and @) pictures in combination with $:

    ? Transform( -5, "@(Z $###,##9.99" )
    ? Transform( -10, "@)Z $###,##9.99" )
    ? Transform( -20, "@Z $###,##9.99" )


  • Fix bug on get picture "@R 99:99"


  • Optimized hb_retc() + hb_xfree() into hb_retcAdopt() in str.c


  • Minor fix to ::asString()


  • New DISABLEWAITLOCKS( [ ] ) -> which disable waiting locks in Windows. It is workaround for delay problem which appears in Windows network server but for sure it's not standard what should be done on xHarbour level. Maybe somewhere in the future MS fix it. For samba it is possible to create a hack with the cost of strict compatibility


  • Changed function FWriteLine( nh, c ) to use Fwrite( nh, CRLF ) instead of Fwrite( nh, chr( 13 ) )+Fwrite( nh, chr( 10 ) ) in Errorsys.prg


  • Fixed BIN2U() to return unsigned numbers for values >= 0x80000000


  • Reverted ValToPrgExp() to use { ... => ... } syntax, as macro compiler now supports it


  • Optimized ValToPrg() for Hashes


  • Deffed out TAssociativeArray() in tobject.ch - superceded by Hash()


  • Added TAssociativeArray() as wrapper for Hash() when no parameters passed, throw error otherwise


  • Added logic to start with default values of clean object in ::LoadFromText() in Persist.prg


  • Made OleShowException() public function


  • SET OPTIMIZE is ON by default now


  • Temporary fix for dump of screen contents in some GTs
xHarbour Preprocessor
  • Fixed WorkMarkers() to NOT accept expression to the left of a matched stopper if the matched stopper is the 2nd. char of a 2 chars operator


  • Few optimizations


  • Fixed support for extended strings (E"...") in getExpReal()


  • Removed #translate rules for Hashes (now native support in parsers)


  • Modified SearnRep() to NOT set 'Group Character' for markers NOT same as the processed 'expiate'. This fixes code like this:

    #xcommand MEMBER [, ] ;
    [ INIT ] ;
    => ;
    _TSTRUCT_: := [; _TSTRUCT_: := ]

    MEMBER Mem1, Mem2, Mem3 INIT "String"


  • Added support for directive #warning
xHarbour Debugger
  • Fixed View CallStack tbrowse position for MAXCOL() > 79
xHarbour RDD
  • Added DBI_RM_SUPPORTED to WA info method (returns FALSE by default)


  • Added some DBI_RM_* actions for dbInfo. It's a initial job to give some basic common to RDD record map filters interface this is work in progress and it can be changed in the future


  • Added DBI_RM_COUNT to dbinfo.ch


  • Fixed problems in __DBLOCATE


  • Simplified hb_waEval() method


  • Changed scoped relations to use DBOI_* interface for scopes


  • OrdScope() changed to use DBOI_*() interface


  • Replaced direct access to pArea->f[EB]of, pArea->fFound with proper method call - direct access does not respect pending relations


  • Updated for proper orderListDelete declaration


  • {PUT,GET}REC() method changed to skip DELETE byte - I'm not 100% it's Clipper compatible. Can someone check it?


  • TRANSREC() method modified for proper whole record coping


  • Use SELF_EVALBLOCK() method to evaluate relation block


  • Use SELF_GOTO() method instead of SELF_GOTOID() - it fixes bad .prg code which sets bad relations without active indexes but it breaks using non numeric RecIDs


  • Clear unused fields in DBEVALINFO


  • Respect non numeric RecID in RLOCK()


  • Respect non numeric RecID in __DBARRANGE()


  • Added 2 as parameter in ordScope() - it sets both scope the return value depends on RDD - ordScope() itself does not try to force it now


  • Added DBOI_SCOPESET, DBOI_SCOPECLEAR to dbinfo.ch


  • Fixed problem in dbedit when UDF Return DE_ABORT, but not quit dbedit


  • Strip trailing spaces from field name in COPY FIELDS ... TO Clipper makes the same


  • Added error message when someone wants to write to index open in read only mode - it avoids infinite locking in POSIX systems


  • Fix ordKeyCount() in descending indexes when not SCOPE/FILTER was active


  • Generate error for bad trailing characters in ALIAS expression (Clipper compatible)


  • Add EF_CANDEFAULT to BAD/DUP ALIAS errors (Clipper compatible)


  • Do not call RT error when there is pending VM request


  • Do not try to set AUTORDER when production index was corrupted
xHarbour DBFCDX
  • In indexing set starting record if not given by user to current record


  • Added compile time macro HB_SIXCDX which builds DBFCDX in SIX compatible mode - generated RDD name is "SIXCDX" - it is less efficient then standard mode but it's a work around for some of SIX bugs - it alows to share CDX indexes with SIX. I do not suggest to use "SIXCDX" as default. It's only for compatibility with Clipper SIX3 driver when it shares indexes with xHarbour application. With standard DBFCDX SIX3 GPFs on compressed trailing spaces in the key values. To create "SIXCDX" you have to set HB_SIXCDX. You can make it by -DHB_SIXCDX compiler switch


  • Force fixed start record for whole database indexes


  • Implemented RT error for some type of currupted indexes


  • The order/tag selection is SIX compatible when compiled in SIXCDX and COMIX compatible in DBFCDX


  • Removed 'init' from the RDD init procedures - it will be called by VM


  • Use FS_END instead of SEEK_END in hb_fsSeek() to avoid problems on platforms which may use differ lseek() values


  • Set the key/for expression to Clipper limit (255) bytes. It is possible in CDX but it breaks documented limit which is 220 due to limitation in IDX header. In fact Clipper allows 256 bytes but I do not want to make it because some other drivers may need trailing 0 byte in stored expression


  • When new index is created with ADDITIVE clause and it is production index then always keep it as first - CL53 compatible


  • Fixed GPF when automatic codepage translation is set and one byte character field retrieve


  • Do not disable read ahead buffer when relation are set It may interacts with some strange code but it is Clipper compatible and if someone needs previous behavior should use SET STRICTREAD switch
xHarbour DBFNTX
  • Fixed GOCOLD() - it should not use current key buffer for previous key value - potential source of different problems


  • Copy the new key in GOCOLD to curkey - it may reduce one key evaluation in some cases


  • Fixed problem caused by unfinished code for operating on empty (without keys) pages


  • Added support for DBOI_SCOPESET, DBOI_SCOPECLEAR


  • Removed SELF_CLEARSCOPE(), SELF_SETSCOPE(), SELF_SCOPEINFO() methods - they will be used in the future for scoped navigation


  • Set default tag selection to be COMIX/CLIPMORE compatible


  • Rewritten from scratch indexing code - it should work on any hardware (little/big endian, 32/64bit, strict alignment), keep the natural order of keys with the same value, works much faster for any type of data and use limited memory buffer


  • Added support for DBOI_KEYSINCLUDED


  • Do not disable read ahead buffer when relation are set It may interacts with some strange code but it is Clipper compatible and if someone needs previous behavior should use SET STRICTREAD switch
xHarbour SIXCDX
  • New sixcdx.lib. It's for compatibility with Clipper SIX3 driver when it shares indexes with xHarbour application. With standard DBFCDX SIX3 GPFs on compressed trailing spaces in the key values


  • Modified the tag selection for SIXCDX - now when only bag is given (without tag) SIXCDX looks for tag with the same name as given bag


  • Implemented exact SIXCDX EVERY evaluation when index is created in SIXCDX (DBFCDX still uses COMIX one) documented by SIX so the following code will works:


    FUNCTION Progress()
    IF Bof()
    // Show Progress screen - always called at beginning
    ELSEIF Eof()
    // Restore screen
    ELSEIF
    // Show index progression - always called at the end
    ENDIF
    RETURN( NIL )
xHarbour DBFFPT
  • Fixed GPF when automatic codepage translation is set and one byte character field retrieve
xHarbour DBFDBT
  • Fixed bug when using codepage translation and the empty string is passed as field value


  • Changed locking mode to be more friendly for DOS/Windows Now you can chose two version of locks. When compiled with:

    DHB_MEMO_SAFELOCK special slower mode is used but you can be sure that you always access proper data. All read and write operation are covered by locks. Without -DHB_MEMO_SAFELOCK standard Clipper compatible locks are used where only WRITE operations are covered by locks and if user wants to be sure he access proper MEMO values then he should make FLOCK or RLOCK on current record. This is default mode (now). if the files are accessed localy then the locking overhead is minimal so the HB_MEMO_SAFELOCK should be default for *nixes in the future. When we add rddInfo() method I'll make locking mode user switchable at runtime - now I do not want to create yet another global set
xHarbour RDDADS
  • Added AdsDirectory(), AdsCheckExistence() and AdsDeleteFile(). Usefull for managing server side temporary files. Connection should be established to use these functions


  • New functions ADSMGKILLUSER() and ADSMGGETHANDLE() Will Return Mg. connection handle to avoid reconnecting the same user i.e. IF AdsMgGetHandle() == 0 AdsMgConnect() ENDIF


  • Added full ord scope support by DBOI_* interface. Now the used method can be freed


  • Fixed scope settings by DBOI_* interface


  • Removed conversion into OEM charset for Ads version 5.x because AdsGetFieldRaw() is not supported by ACE 5.x


  • Fixed GPF trap in adsSetFilter()


  • Added missing #define guard for ADS versions < 6 in adsSetFilter()


  • Incremented numeric fields from 20 to 32 to match ADS specs
xHarbour CT.LIB
  • Added SaveCursor() and RestCursor()


  • Fixed Parameter validating (using now DEFAULT command insted of an forced check of if valtype(var) =="U"


  • Fix in ShowTime() function when called without arguments


  • Added missing FindClose( hFind ) in FileSize()
xHarbour LIBNF.LIB
  • Enabled functions caplock, numlock, alt, ctrl, shift, chdir, rmdir and mkdir


  • Update state of caplock() end numlock()only when argment passed (only return status when no argument passed)


  • Modify return value of ChDir() as per original version


  • Minor enhancement by using static variable for buffer as per original author's suggestion in fttext.c


  • FT_FUSE() now accept 3rd parameter to properly write files with different EOL ie. CHR(13) + CHR(10) (Windows style) and CHR(10) (Unix style). Syntax: FT_FUSE( cFile, nOpenMode, cEOL ) Default cEOL -> hb_conNewLine() as defined in compiler


  • Modify logic in FT_FREADLN() and FT_FSKIP() to respect EOL in file being read. This enables reading Unix or Windows files properly


  • Add error trapper in fttext.c when file operations are performed in an area where no file is opened


  • Modify behaviour of FT_FDELETE() in fttext.c to a more convenient one


  • Fix possible memory leak in _ft_skip() in fttext.c


  • Add FT_FBUFFERSIZE( nNewBuffSize ) -> nOldBuffSize, user defined buffer size for read/write operations in fttext.c


  • Change file read/write/seek method with large modes in fttext.c


  • fttext.c total reworked version using xHarbour array implementation


  • Some minor enhancements in FTText.c
xHarbour GTWVT.LIB
  • IPicture * HB_EXPORT hb_wvt_gtLoadPictureFromResource( LPCSTR cResource, LPCSTR cSection ) Now images can be loaded from resources also


  • #define WVT_PICTURES_MAX 50
    #define WVT_FONTS_MAX 50
    #define WVT_PENS_MAX 50
    #define WVT_DLGML_MAX 50
    #define WVT_DLGMD_MAX 50

    The above values were 20 and now increased to 50 to accomodate more dialogs and pictures


  • hb_wvt_gtRenderPicture() Included if ( _s.bGui ). Was not drawing an image to console buffer
xHarbour GTWVW.LIB
  • Uncomment hb_wvt_gtValidWindowSize() in hb_wvt_gtSetFont() so that wvt_setfont() will fail when it should


  • hb_wv*_gtSetFont() gave wrong return value when it failed


  • Added hb_wvw_gtSetLastMenuEvent()


  • WVW_SETLASTMENUEVENT() callable from .prg


  • Added hb_wvt_gtSetLastMenuEvent()


  • WVT_SETLASTMENUEVENT() callable from .prg


  • Missing function declaration hb_wvt_gtSetLastMenuEvent()


  • Fixed typo: hb_wvw_gtSetLastMenuEvent() --> hb_wvt_gtSetLastMenuEvent()


  • Optimized HB_GT_FUNC( gt_Scroll() ). Now the function is much faster than earlier, avoiding the unnecessary calls to blank the rows which were being copied from proceeding or succeeding rows
xHarbour HBZIP.LIB
  • Fix: When you unzip, restore the current dir correctly


  • Added missing functions HB_UNZIPALLFILE(),HB_GETZIPCOMMENT(), HB_SETZIPCOMMENT(),HB_UNZIPFILEINDEX
 
   
© 2007 xHarbour.org. All rights reserved.
Contact us | Terms of Use Agreement
xHarbour.ORG is maintained by Enrico Maria Giordano
Internet services kindly provided by Bekz.net