Files
harbour-core/harbour/tests/testhrb.prg
Viktor Szakats 4aff1d147d 2013-02-21 17:52 UTC+0100 Viktor Szakats (harbour syenar.net)
* utils/hbmk2/hbmk2.hbp
  * utils/hbmk2/hbmk2.prg
  * utils/hbmk2/Makefile
    ! fixed to not run shell in corner case of:
        hbmk2 -plugin=my.hb [...]
    + documented one missing script/shell API
    + refactored hbmk2/hbshell code to not utilize file wide
      STATIC variables. It allows to _compile_ hbmk2.prg
      regardless of -n option usage
    + added some black magic to be able to _run_ hbmk2.prg
      with or without using -n option
    + additional tricks to avoid defining any unnecessary
      or potentially colliding public functions. It means
      hbmk2/hbrun can now run _itself_ as a script.
      both as .hrb and .prg flavor and regardless of
      -n option usage.

  * contrib/hbcurl/hbcurl.ch
    + added HB_CURLFTP_CREATE_DIR* constants

  * contrib/hbcurl/tests/ftp_uldl.prg
    ! updated FTP test URL
    * cleaned configuration parameters to be strictly
      in sync with libcurl docs
    + do not disable SSL host/peer verifications

  * tests/testhrb.prg
  * src/vm/runner.c
    * misc comment cleanup

  * tests/testhtml.prg
    * code cleanup

  * contrib/gtwvg/gtwgud.c
  * contrib/gtwvg/gtwvgd.c
  * contrib/hbgt/bitflags.c
  * contrib/hbmysql/readme.txt
  * contrib/hbmysql/tests/dbf2mysq.prg
  * contrib/hbmysql/tsqlbrw.prg
  * contrib/hbtip/mail.prg
  * contrib/rddads/ads1.c
  * contrib/xhb/dumpvar.prg
  * contrib/xhb/xhbmemo.prg
  * contrib/xhb/xhbtedit.prg
  * doc/gtapi.txt
  * extras/gtwvw/gtwvwd.c
  * extras/hbxlsxml/tests/example.prg
  * extras/httpsrv/uhttpd.prg
  * src/debug/dbgtarr.prg
  * src/debug/dbgthsh.prg
  * src/lang/l_sk.c
  * src/rdd/dbfcdx/dbfcdx1.c
  * src/rdd/usrrdd/rdds/arrayrdd.prg
  * src/rtl/filesys.c
  * src/rtl/gtos2/gtos2.c
  * src/rtl/gtwvt/gtwvt.c
  * src/rtl/net.c
  * src/rtl/teditor.prg
  * src/vm/thread.c
  * website/news1.html
    * cleaned all remaining national/misc dates
      to be in ANSI format (YYYY.MM.DD)
2013-02-21 16:55:35 +00:00

58 lines
1.3 KiB
Plaintext

/*
* $Id$
*/
// see also exthrb.prg
#include "hbhrb.ch"
PROCEDURE Main( x )
LOCAL pHrb, cExe := "Msg2()"
LOCAL n := iif( x == NIL, 0, Val( x ) )
? "calling Msg ... From exe here !"
Msg()
? "========================="
#if 0
? "Loading( 'exthrb.hrb' )"
pHrb := hb_hrbLoad( "exthrb.hrb" )
? "Loading( HB_HRB_BIND_DEFAULT, 'exthrb.hrb' )"
pHrb := hb_hrbLoad( HB_HRB_BIND_DEFAULT, "exthrb.hrb" )
? "Loading( HB_HRB_BIND_LOCAL, 'exthrb.hrb' )"
pHrb := hb_hrbLoad( HB_HRB_BIND_LOCAL, "exthrb.hrb" )
#endif
? "Loading(" + iif( n == 0, "HB_HRB_BIND_DEFAULT", iif( n == 1, "HB_HRB_BIND_LOCAL", "HB_HRB_BIND_OVERLOAD" ) ) + ", 'exthrb.hrb' )"
pHrb := hb_hrbLoad( n, "exthrb.hrb" )
? "========================="
? "calling Msg ... DEFAULT=From exe, LOCAL=From exe, OVERLOAD=From HRB"
Msg()
? "========================="
? "calling Msg ... DEFAULT=From exe, LOCAL=From HRB, OVERLOAD=From HRB"
&cExe //
? "========================="
hb_hrbUnload( pHrb ) // should do nothing in case of OVERLOAD
? "calling Msg ... DEFAULT=From exe, LOCAL=From exe, OVERLOAD=From HRB"
Msg() // test unload protection when using OVERLOAD ... then .hrb not anymore unloadable
? "========================="
? "END"
RETURN
FUNCTION Msg()
? "Function called from Exe"
RETURN .T.