* contrib/hbmzip/hbmzip.c
! Fixed potential GPF in executable type detection.
Fixes GCC 4.3.1 warnings in openSUSE 11.
* tests/debugtst.prg
* tests/funcarr.prg
* tests/inherit.prg
* tests/objarr.prg
* tests/objasign.prg
* doc/en/hvm.txt
* doc/es/hvm.txt
* include/hbextern.ch
* source/vm/debug.c
* source/vm/hvm.c
* source/debug/dbgtobj.prg
* source/debug/debugger.prg
* source/rtl/altd.prg
* Harbour level HB_DBG_*() functions renamed to __DBG*() to
reflect their internal nature.
- Removed old __VM*() synonyms to Harbour level __DBG*() functions.
INCOMPATIBLE.
! Fixed a few minor doc bugs along the way.
63 lines
1.2 KiB
Plaintext
63 lines
1.2 KiB
Plaintext
//
|
|
// $Id$
|
|
//
|
|
|
|
//
|
|
// Function Array syntax test
|
|
//
|
|
// Written by Eddie Runia <eddie@runia.com>
|
|
// www - http://www.harbour-project.org
|
|
//
|
|
// Placed in the public domain
|
|
//
|
|
|
|
Function Main
|
|
|
|
local a
|
|
|
|
QOut( "Direct reference : ", aFunc()[1] )
|
|
|
|
a := aFunc()
|
|
QOut( "Ref via array : ", a[1] )
|
|
|
|
aFunc()[1] := "Something different"
|
|
QOut( "Assign new text : ", aFunc()[1] )
|
|
|
|
aFunc()[1] := 4
|
|
QOut( "Assign 4 : ", aFunc()[1] )
|
|
|
|
QOut( "Post increment : ", aFunc()[1]++ )
|
|
QOut( "After : ", aFunc()[1] )
|
|
QOut( "Pre decrement : ", --aFunc()[1] )
|
|
QOut( "After : ", aFunc()[1] )
|
|
|
|
aFunc()[1] += 2
|
|
QOut( "Plus 2 : ", aFunc()[1] )
|
|
|
|
aFunc()[1] -= 3
|
|
QOut( "Minus 3 : ", aFunc()[1] )
|
|
|
|
aFunc()[1] *= 3
|
|
QOut( "Times 3 : ", aFunc()[1] )
|
|
|
|
aFunc()[1] /= 1.5
|
|
QOut( "Divide by 1.5 : ", aFunc()[1] )
|
|
|
|
aFunc()[1] %= 4
|
|
QOut( "Modulus 4 : ", aFunc()[1] )
|
|
|
|
aFunc()[1] ^= 3
|
|
QOut( "To the power 3 : ", aFunc()[1] )
|
|
|
|
QOut( "Global stack" )
|
|
Debug( __dbgvmStkGList() ) // Please note a is a reference to aArray !
|
|
QOut( "Statics")
|
|
Debug( __dbgvmVarSList() )
|
|
return NIL
|
|
|
|
Function aFunc()
|
|
|
|
static aArray := { [Test] }
|
|
|
|
return aArray
|