Harbour Differences

Differences between Harbour and other compatible compilers ( xHarbour, Clipper, xBase++, CLIP, FlagShip )

 

Compile time support for merging multiple .prg modules
New language statements
FOR EACH
WITH OBJECT / END[WITH]
SWITCH / [ CASE / [EXIT] / … ] OTHERWISE / END[SWITCH]
BEGIN SEQUENCE [ WITH <ERRBLOCK> ] … END SEQUENCE
Extended codeblocks
Hash arrays
References to variables stored in arrays
Passing array and hash items by reference
Passing object variables by reference
Detached locals and references
Declaration and initialization of variables
Functions with variable number of parameters
Hb_ArrayToParams() function
Macros with declared symbols
Macro messages
Multivalue macros
Using [] operator for string items
Negative indexes in [] operator used to access items from tail
Using one character length string as numeric value
New bit operators
IN, HAS, LIKE operators
Pre/post incrementation/decrementation and <op>= operators
Global / global external (global_extern)
DATETIME/TIMESTAMP values
Literal date and TIMESTAMP values
Extended literal string in compiler and macrocompiler
Symbol items and function references
OOP scopes
OOP and multiinheritance
OOP and private/hidden datas
OOP and class object/class messages
Typed object variables
Object destructors
Scalar classes
Runtime class modification
Array and string preallocation
DIVERT statement
Namespaces
Multi window GTs and runtime GT switching
Multi thread support
Thread local work areas and concurrent work area access
Harbour tasks and MT support in DOS
Background task
Codeblock serialization / deserialization
Native RDDs
Regular expressions
INET sockets
I18N (internationalization) support
ZLIB (compression/decompression)
Serial port support
Macro compiler
Compiler library
PP library
Lexer
Contrib libraries
Portability
C level compatibility
HBRUN / XBSCRIPT
HBMK2
Performance and resource usage

This list borrowed from Harbour github documentation; please look at there for details.

 

Advertisements

Harbour String Functions

AddASCII

AfterAtNum

AllTrim
Asc

ASCIISum

ASCPos
At

AtAdjust

AtNum
AtRepl
AtToken

BeforAtNum

Chr

CharAdd
CharAnd
CharEven
CharHist
CharList
CharMirr
CharMix
CharNoList
CharNot
CharOdd
CharOne
CharOnly
CharOr
CharPix
CharRela
CharRelRep
CharRem
CharRepl
CharRLL
CharRLR
CharSHL
CharSHR
CharSList
CharSort
CharSub
CharSwap
CharWin
CharXOR

CountLeft
CountRight
Descend
Empty
hb_At
hb_RAt
hb_ValToStr
IsAlpha
IsDigit
IsLower
IsUpper

JustLeft
JustRight

Left
Len
Lower
LTrim

NumAt
NumToken
PadLeft
PadRight

PadC
PadL
PadR

POSALPHA
POSCHAR
POSDEL
POSDIFF
POSEQUAL
POSINS
POSLOWER
POSRANGE
POSREPL
POSUPPER

RangeRem
RangeRepl

RAt

RemAll

RemLeft
RemRight
ReplAll

Replicate

ReplLeft

ReplRight

RestToken

Right
RTrim

SaveToken

SetAtLike
Space
Str

StrDiff

StrFormat

StrSwap

StrTran
StrZero
SubStr

TabExpand
TabPack

Token

TokenAt
TokenEnd
TokenExit
TokenInit
TokenLower
TokenNext
TokenNum
TokenSep
TokenUpper

Transform
Trim
Upper
Val

ValPos
WordOne
WordOnly
WordRem
WordRepl
WordSwap

WordToChar


SP String Functions

 SUBPLUS()      Returns multiple substrings
 STRPULL()      Extract text between 2 characters
 TAKEOUT()      Extract a portion of a string between delimiters at
                nth occurrance
 CRUNCH()       Moves spaces in a string to end of string
 ADDSPACE()     Pads right of string with spaces
 ARRANGE()      Rearranges text in a string
 CENTR()        Centers a string in x spaces
 _WILDCARD()    Wild Card String Compare
 ALLBUT()       Returns all but last x characters
 STRETCH()      Imbeds characters in a string
 LJUST()        Left justifies a string
 STARTSW()      Determines if a string starts with another string
 VAR2CHAR()     Converts any type variable to character type
 RJUST()        Right justifies a string
 PROPER()       Capitalizes first letters of string, lowers rest

SP_TRUEVAL

TRUEVAL()

  Short:
  ------
  TRUEVAL() Returns val of ALL numerics in a string

  Returns:
  --------
  <nValue> => all numerics value

  Syntax:
  -------
  TRUEVAL(cString)

  Description:
  ------------
  Removes all non-numeric characters from a <cString>,
  and then converts it to numeric.

  Examples:
  ---------
   cString := "SUPERFUNCTION Library version 3.00"

   cNumber := TRUEVAL(cString)

   // (returns 3.0)

  Source:
  -------
  S_TRUEVA.PRG

 

SP_STRPULL

STRPULL()

  Short:
  ------
  STRPULL() Extract text between 2 characters in a string

  Returns:
  --------
  <cExtract> => text extracted

  Syntax:
  -------
  STRPULL(cSource,cDelim1,cDelim2)

  Description:
  ------------
  Extracts text from <cSource> between characters
  <cDelim1> and <cDelim2>.

  If <cDelim1> is empty, uses beginning of <cSource>.

  If <cDelim2> is empty, uses end of <cSource>.

  Examples:
  ---------
   cString := "SUPERFUNCTION"

   cString := STRPULL(cString,'E','C')

   // (returns "RFUN")

  Source:
  -------
  S_STRPUL.PRG

 

SP_STRETCH

STRETCH()

  Short:
  ------
  STRETCH() Embeds characters in a string

  Returns:
  --------
  <cStretched> => string with characters imbedded

  Syntax:
  -------
  STRETCH(cSource,cFill,nEvery)

  Description:
  ------------
  Imbeds character <cFill> in string <cSource> every
  <nEvery> character

  Examples:
  ---------
   cString := "SUPERFUNCTION"

   cString := STRETCH(cString,' ',1)

   // (returns "S U P E R F U N C T I O N")

  Notes:
  -------
  This name might be called EXPAND in other parts

  Source:
  -------
  S_STRETC.PRG

 

SP_STARTSW

STARTSW()

  Short:
  ------
  STARTSW() Determines if a string starts with another string

  Returns:
  --------
  <lStartsWith> => String 1 starts with string 2

  Syntax:
  -------
  STARTSW(cTarget,cStarts)

  Description:
  ------------
  Determines if string 1 <cTarget> starts with string 2
  <cStarts>

  Examples:
  ---------
   cStr1    := "SUPERFUNCTION"

   cStr2    := "SUPER"

   cStr3    := "SOUP"

   STARTSW(cStr1,cStr2)    //returns .t.

   STARTSW(cStr1,cStr3)    //returns .f.

  Source:
  -------
  S_STARTS.PRG