From ff5b91e7e439b40701674f449920af5f17306b83 Mon Sep 17 00:00:00 2001 From: Viktor Szakats Date: Thu, 16 Sep 1999 03:41:57 +0000 Subject: [PATCH] 19990916-05:30 GMT+1 --- harbour/ChangeLog | 26 +++++++++++++ harbour/build16.bat | 3 +- harbour/build31.bat | 3 +- harbour/build32.bat | 3 +- harbour/build40.bat | 3 +- harbour/buildvc.bat | 3 +- harbour/genbuild.bat | 3 +- harbour/include/hberrors.h | 2 + harbour/source/compiler/harbour.y | 36 +++++++++++------ harbour/source/rtl/tclass.prg | 59 ++++++++++++++-------------- harbour/source/rtl/terror.prg | 58 ++++++++++++++-------------- harbour/source/rtl/tget.prg | 58 ++++++++++++++-------------- harbour/source/rtl/tgetlist.prg | 58 ++++++++++++++-------------- harbour/source/rtl/xsavescr.prg | 31 +++++++++++++++ harbour/tests/working/Makefile | 1 - harbour/tests/working/bld32exe.bat | 3 +- harbour/tests/working/bld32obj.bat | 3 +- harbour/tests/working/bld32w.bat | 3 +- harbour/tests/working/bldpexe.bat | 3 +- harbour/tests/working/build.bat | 2 +- harbour/tests/working/buildexe.bat | 3 +- harbour/tests/working/buildvc.bat | 3 +- harbour/tests/working/hb.bat | 3 +- harbour/tests/working/hb32.bat | 3 +- harbour/tests/working/hb32w.bat | 3 +- harbour/tests/working/hbp.bat | 3 +- harbour/tests/working/hbrun.bat | 3 +- harbour/tests/working/hbvc.bat | 3 +- harbour/tests/working/rtl_test.prg | 62 ++++++++++++++++-------------- harbour/tests/working/run_all.bat | 3 +- harbour/tests/working/setkeys.prg | 6 +-- 31 files changed, 256 insertions(+), 200 deletions(-) diff --git a/harbour/ChangeLog b/harbour/ChangeLog index 5f6749e8bb..51bf7d844d 100644 --- a/harbour/ChangeLog +++ b/harbour/ChangeLog @@ -1,3 +1,29 @@ +19990916-05:30 GMT+1 Victor Szel + + * source/compiler/harbour.y + include/hberrors.h + ! Proper error shown when more than one input (.prg) filenames are + specified, it caused a leak previously and was not compatible with + Clipper. + ! Invalid filename message when the passed filename only contains dir/drive. + GPF fixed. + * *.bat + tests/working/*.bat + ! @echo off commands moved to the top of files. + * tests/working/setkeys.prg + ! Some functions names fixed, it still doesn't work because GetActive() + function is not yet implemented. + * tests/working/rtl_test.prg + tests/working/transdef.prg (removed) + tests/working/Makefile + * Tests from transdef.prg moved to rtl_test.prg (2 failures more now) + * tests/broken/parexpr.prg + - Removed, since it's in working now. + ; The bugs above were reported by Jose Lalin. + * source/rtl/*.* (partial) + + All copyright header changed to the new one. + + Missing copyright headers added. + 19990916-03:57 GMT+1 Victor Szel * source/rdd/* diff --git a/harbour/build16.bat b/harbour/build16.bat index dae4900401..63aad0589d 100644 --- a/harbour/build16.bat +++ b/harbour/build16.bat @@ -1,8 +1,7 @@ +@echo off rem rem $Id$ rem -@echo off - make -fmakefile.b16 rem make -fhbpp.b16 diff --git a/harbour/build31.bat b/harbour/build31.bat index 7ae29b1694..965f5bc46a 100644 --- a/harbour/build31.bat +++ b/harbour/build31.bat @@ -1,8 +1,7 @@ +@echo off rem rem $Id$ rem -@echo off - if %1.==hb. make -fharbour.b31 -r %2 if not %1.==hb. make -fmakefile.b31 -r %1 diff --git a/harbour/build32.bat b/harbour/build32.bat index 9b90f26ce6..35c5d62620 100644 --- a/harbour/build32.bat +++ b/harbour/build32.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - make -fhbpplib.b32 > build32.err make -fmakefile.b32 >> build32.err make -fterminal.b32 >> build32.err diff --git a/harbour/build40.bat b/harbour/build40.bat index 15602e1864..0ee1d89a29 100644 --- a/harbour/build40.bat +++ b/harbour/build40.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - make -fhbpplib.b32 > build40.err make -fmakefile.b40 >> build40.err make -fterminal.b32 >> build40.err diff --git a/harbour/buildvc.bat b/harbour/buildvc.bat index f62f6ed289..519bc22a25 100644 --- a/harbour/buildvc.bat +++ b/harbour/buildvc.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - del buildVC.err masm source\compiler\symbols.asm obj\symbols.obj obj\symbols.lst obj\symbols.crf > BuildVC.err nmake /f makefile.vc >> BuildVC.err diff --git a/harbour/genbuild.bat b/harbour/genbuild.bat index e6b91d54c8..bf37d43dc8 100644 --- a/harbour/genbuild.bat +++ b/harbour/genbuild.bat @@ -1,8 +1,7 @@ +@echo off rem rem $Id$ rem -@echo off - cd.. pkzip -r -p harb21-2 -x*.exe -x*.bak -x*.sim -x*.out -xsave.bat -xlexyy.c -xy_tab.c -xy_tab.h -x*.obj -x*.lib -x*.zip diff --git a/harbour/include/hberrors.h b/harbour/include/hberrors.h index 706feddd0b..946f4771b1 100644 --- a/harbour/include/hberrors.h +++ b/harbour/include/hberrors.h @@ -73,6 +73,8 @@ #define ERR_CREATE_OUTPUT 32 #define ERR_CREATE_PPO 33 #define ERR_BADOPTION 34 +#define ERR_BADPARAM 35 +#define ERR_BADFILENAME 36 #define WARN_AMBIGUOUS_VAR 1 #define WARN_MEMVAR_ASSUMED 2 diff --git a/harbour/source/compiler/harbour.y b/harbour/source/compiler/harbour.y index 288b022022..c227067199 100644 --- a/harbour/source/compiler/harbour.y +++ b/harbour/source/compiler/harbour.y @@ -311,7 +311,9 @@ char * _szCErrors[] = "Jump offset too long", "Can't create output file: \'%s\'", "Can't create preprocessed output file: \'%s\'", - "Bad command line option: \'%s\'" + "Bad command line option: \'%s\'", + "Bad command line parameter: \'%s\'", + "Invalid filename: \'%s\'" }; /* Table with parse warnings */ @@ -1371,6 +1373,8 @@ int harbour_main( int argc, char * argv[] ) char szPpoName[ _POSIX_PATH_MAX ]; PHB_FNAME pOutPath = NULL; + _pFileName = NULL; + Hbpp_init(); /* Initialization of preprocessor arrays */ /* Command line options */ for( iArg = 1; iArg < argc; iArg++ ) @@ -1435,11 +1439,11 @@ int harbour_main( int argc, char * argv[] ) break; default: - GenError( _szCErrors, 'E', ERR_BADOPTION, &argv[ iArg ][ 0 ], NULL ); + GenError( _szCErrors, 'E', ERR_BADOPTION, argv[ iArg ], NULL ); } } else - GenError( _szCErrors, 'E', ERR_BADOPTION, &argv[ iArg ][ 0 ], NULL ); + GenError( _szCErrors, 'E', ERR_BADOPTION, argv[ iArg ], NULL ); break; case 'g': @@ -1495,7 +1499,7 @@ int harbour_main( int argc, char * argv[] ) case 'm': case 'M': /* TODO: Implement this switch */ - printf( "Not yet supported command line option: %s\n", &argv[ iArg ][ 0 ] ); + printf( "Not yet supported command line option: %s\n", argv[ iArg ] ); break; case 'n': @@ -1522,7 +1526,7 @@ int harbour_main( int argc, char * argv[] ) case 'r': case 'R': /* TODO: Implement this switch */ - printf( "Not yet supported command line option: %s\n", &argv[ iArg ][ 0 ] ); + printf( "Not yet supported command line option: %s\n", argv[ iArg ] ); break; case 's': @@ -1533,13 +1537,13 @@ int harbour_main( int argc, char * argv[] ) case 't': case 'T': /* TODO: Implement this switch */ - printf( "Not yet supported command line option: %s\n", &argv[ iArg ][ 0 ] ); + printf( "Not yet supported command line option: %s\n", argv[ iArg ] ); break; case 'u': case 'U': /* TODO: Implement this switch */ - printf( "Not yet supported command line option: %s\n", &argv[ iArg ][ 0 ] ); + printf( "Not yet supported command line option: %s\n", argv[ iArg ] ); break; case 'v': @@ -1579,15 +1583,25 @@ int harbour_main( int argc, char * argv[] ) break; default: - GenError( _szCErrors, 'E', ERR_BADOPTION, &argv[ iArg ][ 0 ], NULL ); + GenError( _szCErrors, 'E', ERR_BADOPTION, argv[ iArg ], NULL ); break; } } else if( argv[ iArg ][ 0 ] == '@' ) /* TODO: Implement this switch */ - printf( "Not yet supported command line option: %s\n", &argv[ iArg ][ 0 ] ); + printf( "Not yet supported command line option: %s\n", argv[ iArg ] ); else - _pFileName = hb_fsFNameSplit( argv[ iArg ] ); + { + if( _pFileName ) + GenError( _szCErrors, 'E', ERR_BADPARAM, argv[ iArg ], NULL ); + else + { + _pFileName = hb_fsFNameSplit( argv[ iArg ] ); + + if( ! _pFileName->szName ) + GenError( _szCErrors, 'E', ERR_BADFILENAME, argv[ iArg ], NULL ); + } + } } if( _pFileName ) @@ -1748,7 +1762,7 @@ int harbour_main( int argc, char * argv[] ) } else { - printf( "Can't open input file: %s\n", szFileName ); + printf( "Cannot open input file: %s\n", szFileName ); iStatus = 1; } hb_xfree( ( void * ) _pFileName ); diff --git a/harbour/source/rtl/tclass.prg b/harbour/source/rtl/tclass.prg index 69cdeccde5..7d2baf3362 100644 --- a/harbour/source/rtl/tclass.prg +++ b/harbour/source/rtl/tclass.prg @@ -3,36 +3,35 @@ */ /* - Harbour Project source code - - Harbour Base Class - - Copyright 1999 Antonio Linares - www - http://www.harbour-project.org - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version, with one exception: - - The exception is that if you link the Harbour Runtime Library (HRL) - and/or the Harbour Virtual Machine (HVM) with other files to produce - an executable, this does not by itself cause the resulting executable - to be covered by the GNU General Public License. Your use of that - executable is in no way restricted on account of linking the HRL - and/or HVM code into it. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit - their web site at http://www.gnu.org/). -*/ - + * Harbour Project source code: + * Base Class + * + * Copyright 1999 Antonio Linares + * www - http://www.harbour-project.org + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version, with one exception: + * + * The exception is that if you link the Harbour Runtime Library (HRL) + * and/or the Harbour Virtual Machine (HVM) with other files to produce + * an executable, this does not by itself cause the resulting executable + * to be covered by the GNU General Public License. Your use of that + * executable is in no way restricted on account of linking the HRL + * and/or HVM code into it. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit + * their web site at http://www.gnu.org/). + * + */ /* Harbour Project source code http://www.Harbour-Project.org/ diff --git a/harbour/source/rtl/terror.prg b/harbour/source/rtl/terror.prg index 164972ef98..ad217d7c42 100644 --- a/harbour/source/rtl/terror.prg +++ b/harbour/source/rtl/terror.prg @@ -3,35 +3,35 @@ */ /* - Harbour Project source code - - Harbour Error Class - - Copyright 1999 Antonio Linares - www - http://www.harbour-project.org - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version, with one exception: - - The exception is that if you link the Harbour Runtime Library (HRL) - and/or the Harbour Virtual Machine (HVM) with other files to produce - an executable, this does not by itself cause the resulting executable - to be covered by the GNU General Public License. Your use of that - executable is in no way restricted on account of linking the HRL - and/or HVM code into it. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit - their web site at http://www.gnu.org/). -*/ + * Harbour Project source code: + * Class Error + * + * Copyright 1999 Antonio Linares + * www - http://www.harbour-project.org + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version, with one exception: + * + * The exception is that if you link the Harbour Runtime Library (HRL) + * and/or the Harbour Virtual Machine (HVM) with other files to produce + * an executable, this does not by itself cause the resulting executable + * to be covered by the GNU General Public License. Your use of that + * executable is in no way restricted on account of linking the HRL + * and/or HVM code into it. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit + * their web site at http://www.gnu.org/). + * + */ /* Error Class. We are keeping Clipper compatibility here, instead of using TError():New() style and also avoiding hungarian notation. */ diff --git a/harbour/source/rtl/tget.prg b/harbour/source/rtl/tget.prg index b32c916745..bc64810abd 100644 --- a/harbour/source/rtl/tget.prg +++ b/harbour/source/rtl/tget.prg @@ -3,35 +3,35 @@ */ /* - Harbour Project source code - - Harbour Get Class - - Copyright 1999 Ignacio Ortiz de Zúniga - www - http://www.harbour-project.org - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version, with one exception: - - The exception is that if you link the Harbour Runtime Library (HRL) - and/or the Harbour Virtual Machine (HVM) with other files to produce - an executable, this does not by itself cause the resulting executable - to be covered by the GNU General Public License. Your use of that - executable is in no way restricted on account of linking the HRL - and/or HVM code into it. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit - their web site at http://www.gnu.org/). -*/ + * Harbour Project source code: + * Class Get + * + * Copyright 1999 Ignacio Ortiz de Zúniga + * www - http://www.harbour-project.org + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version, with one exception: + * + * The exception is that if you link the Harbour Runtime Library (HRL) + * and/or the Harbour Virtual Machine (HVM) with other files to produce + * an executable, this does not by itself cause the resulting executable + * to be covered by the GNU General Public License. Your use of that + * executable is in no way restricted on account of linking the HRL + * and/or HVM code into it. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit + * their web site at http://www.gnu.org/). + * + */ #include "classes.ch" #include "color.ch" diff --git a/harbour/source/rtl/tgetlist.prg b/harbour/source/rtl/tgetlist.prg index 68a394e9e3..737b322d6f 100644 --- a/harbour/source/rtl/tgetlist.prg +++ b/harbour/source/rtl/tgetlist.prg @@ -3,35 +3,35 @@ */ /* - Harbour Project source code - - Harbour GetList Class - - Copyright 1999 Antonio Linares - www - http://www.harbour-project.org - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version, with one exception: - - The exception is that if you link the Harbour Runtime Library (HRL) - and/or the Harbour Virtual Machine (HVM) with other files to produce - an executable, this does not by itself cause the resulting executable - to be covered by the GNU General Public License. Your use of that - executable is in no way restricted on account of linking the HRL - and/or HVM code into it. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit - their web site at http://www.gnu.org/). -*/ + * Harbour Project source code: + * Class GetList + * + * Copyright 1999 Antonio Linares + * www - http://www.harbour-project.org + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version, with one exception: + * + * The exception is that if you link the Harbour Runtime Library (HRL) + * and/or the Harbour Virtual Machine (HVM) with other files to produce + * an executable, this does not by itself cause the resulting executable + * to be covered by the GNU General Public License. Your use of that + * executable is in no way restricted on account of linking the HRL + * and/or HVM code into it. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit + * their web site at http://www.gnu.org/). + * + */ #include "classes.ch" #include "getexit.ch" diff --git a/harbour/source/rtl/xsavescr.prg b/harbour/source/rtl/xsavescr.prg index 20457461c6..c8aa059073 100644 --- a/harbour/source/rtl/xsavescr.prg +++ b/harbour/source/rtl/xsavescr.prg @@ -2,6 +2,37 @@ * $Id$ */ +/* + * Harbour Project source code: + * __XSAVESCREEN()/__XRESTSCREEN() + * + * Copyright 1999 Paul Tucker + * www - http://www.harbour-project.org + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version, with one exception: + * + * The exception is that if you link the Harbour Runtime Library (HRL) + * and/or the Harbour Virtual Machine (HVM) with other files to produce + * an executable, this does not by itself cause the resulting executable + * to be covered by the GNU General Public License. Your use of that + * executable is in no way restricted on account of linking the HRL + * and/or HVM code into it. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit + * their web site at http://www.gnu.org/). + * + */ + STATIC s_cScrn PROCEDURE __XSAVESCREEN() diff --git a/harbour/tests/working/Makefile b/harbour/tests/working/Makefile index 938896015a..ba39c0464c 100644 --- a/harbour/tests/working/Makefile +++ b/harbour/tests/working/Makefile @@ -144,7 +144,6 @@ PRG_SOURCES=\ testvars.prg \ testwarn.prg \ tstcolor.prg \ - transdef.prg \ val.prg \ version.prg \ while.prg \ diff --git a/harbour/tests/working/bld32exe.bat b/harbour/tests/working/bld32exe.bat index 13b397875c..2a0ddc18b4 100644 --- a/harbour/tests/working/bld32exe.bat +++ b/harbour/tests/working/bld32exe.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - IF A%1 == A GOTO :SINTAX IF A%2 == A GOTO :NOOUTPUT diff --git a/harbour/tests/working/bld32obj.bat b/harbour/tests/working/bld32obj.bat index a5539bdc1d..4c0f5e9697 100644 --- a/harbour/tests/working/bld32obj.bat +++ b/harbour/tests/working/bld32obj.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - ..\..\bin\harbour %1 /fobj32 /n /i..\..\include tlink32 -L..\..\libs\b32;c:\bc5\lib c:\bc5\lib\c0x32.obj %1.obj hvm.obj,%1.exe,, harbour.lib terminal.lib import32.lib cw32mt.lib diff --git a/harbour/tests/working/bld32w.bat b/harbour/tests/working/bld32w.bat index 0c06793065..fd0a08286c 100644 --- a/harbour/tests/working/bld32w.bat +++ b/harbour/tests/working/bld32w.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - IF A%1 == A GOTO :SINTAX IF A%2 == A GOTO :NOOUTPUT diff --git a/harbour/tests/working/bldpexe.bat b/harbour/tests/working/bldpexe.bat index 1aed25d4b2..e7573d90d3 100644 --- a/harbour/tests/working/bldpexe.bat +++ b/harbour/tests/working/bldpexe.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - IF A%1 == A GOTO :SINTAX IF A%2 == A GOTO :NOOUTPUT diff --git a/harbour/tests/working/build.bat b/harbour/tests/working/build.bat index 72d4b19f11..3358ed26e6 100644 --- a/harbour/tests/working/build.bat +++ b/harbour/tests/working/build.bat @@ -1,8 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off if %hb_architecture%.==. goto bad_arch if %hb_compiler%.==. goto bad_comp if exist %hb_architecture\%hb_compiler\%1.* del %hb_architecture\%hb_compiler\%1.* diff --git a/harbour/tests/working/buildexe.bat b/harbour/tests/working/buildexe.bat index 1b5c3634fe..3e6827c6ac 100644 --- a/harbour/tests/working/buildexe.bat +++ b/harbour/tests/working/buildexe.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - IF A%1 == A GOTO :SINTAX IF A%2 == A GOTO :NOOUTPUT diff --git a/harbour/tests/working/buildvc.bat b/harbour/tests/working/buildvc.bat index 3524b6c40d..9a29eb69fe 100644 --- a/harbour/tests/working/buildvc.bat +++ b/harbour/tests/working/buildvc.bat @@ -1,8 +1,7 @@ +@echo off rem rem $Id$ rem -@echo off - ..\..\bin\harbour %1 /n /i..\..\include cl -Fd..\..\bin\harbour -w -Zi -TP -GZ -GA -DDEBUG -DHARBOUR_USE_GTAPI -DHARBOUR_USE_WIN_GTAPI -I..\..\include %1.c /link /subsystem:CONSOLE ..\..\obj\symbols.obj ..\..\libs\vc\harbour.lib ..\..\libs\vc\terminal.lib ..\..\libs\vc\hbtools.lib ..\..\libs\vc\dbfntx.lib ..\..\libs\vc\debug.lib diff --git a/harbour/tests/working/hb.bat b/harbour/tests/working/hb.bat index 87e464ac22..654f9a0fda 100644 --- a/harbour/tests/working/hb.bat +++ b/harbour/tests/working/hb.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - REM From .PRG to .C = Harbour ..\..\bin\harbour %1.prg /n /i..\..\include if errorlevel 1 goto end diff --git a/harbour/tests/working/hb32.bat b/harbour/tests/working/hb32.bat index 8b89104905..bd3164054c 100644 --- a/harbour/tests/working/hb32.bat +++ b/harbour/tests/working/hb32.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - REM From .PRG to .C = Harbour ..\..\bin\harbour %1.prg %2 /n /i..\..\include if errorlevel 1 goto end diff --git a/harbour/tests/working/hb32w.bat b/harbour/tests/working/hb32w.bat index 4f79a2ab49..0033a2bd85 100644 --- a/harbour/tests/working/hb32w.bat +++ b/harbour/tests/working/hb32w.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - REM From .PRG to .C = Harbour ..\..\bin\harbour %1.prg /n /i..\..\include if errorlevel 1 goto end diff --git a/harbour/tests/working/hbp.bat b/harbour/tests/working/hbp.bat index ce16e456f3..b8ad41c531 100644 --- a/harbour/tests/working/hbp.bat +++ b/harbour/tests/working/hbp.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - REM From .PRG to .C = Harbour ..\..\bin\harbour %1.prg /n /i..\..\include if errorlevel 1 goto end diff --git a/harbour/tests/working/hbrun.bat b/harbour/tests/working/hbrun.bat index 4859df8843..5b38cc04ec 100644 --- a/harbour/tests/working/hbrun.bat +++ b/harbour/tests/working/hbrun.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - REM From .PRG to .C = Harbour ..\..\bin\harbour %1.prg /n /gHRB /i..\..\include runner %1.hrb diff --git a/harbour/tests/working/hbvc.bat b/harbour/tests/working/hbvc.bat index 15e0dd6cc4..9a5932254c 100644 --- a/harbour/tests/working/hbvc.bat +++ b/harbour/tests/working/hbvc.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - REM From .PRG to .C = Harbour ..\..\bin\harbour %1.prg /n /i..\..\include diff --git a/harbour/tests/working/rtl_test.prg b/harbour/tests/working/rtl_test.prg index 7ae3206232..0b92ae8ef0 100644 --- a/harbour/tests/working/rtl_test.prg +++ b/harbour/tests/working/rtl_test.prg @@ -3,35 +3,35 @@ */ /* - Harbour Project source code - - Runtime library regression tests. - - Copyright (C) 1999 Victor Szel - www - http://www.harbour-project.org - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version, with one exception: - - The exception is that if you link the Harbour Runtime Library (HRL) - and/or the Harbour Virtual Machine (HVM) with other files to produce - an executable, this does not by itself cause the resulting executable - to be covered by the GNU General Public License. Your use of that - executable is in no way restricted on account of linking the HRL - and/or HVM code into it. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit - their web site at http://www.gnu.org/). -*/ + * Harbour Project source code: + * Runtime library regression tests + * + * Copyright 1999 Victor Szel + * www - http://www.harbour-project.org + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version, with one exception: + * + * The exception is that if you link the Harbour Runtime Library (HRL) + * and/or the Harbour Virtual Machine (HVM) with other files to produce + * an executable, this does not by itself cause the resulting executable + * to be covered by the GNU General Public License. Your use of that + * executable is in no way restricted on account of linking the HRL + * and/or HVM code into it. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA (or visit + * their web site at http://www.gnu.org/). + * + */ /* TRANSFORM() tests written by Eddie Runia */ /* EMPTY() tests written by Eddie Runia */ @@ -1409,6 +1409,7 @@ STATIC FUNCTION Main_STRINGS() TEST_LINE( Transform( .F. , "@R Y" ) , "N" ) TEST_LINE( Transform( .T. , "@R X!" ) , "X!T" ) + TEST_LINE( Transform( SToD("20000101") , "@B" ) , "2000.01.01" ) TEST_LINE( Transform( SToD("19901214") , "99/99/9999" ) , "1990.12.14" ) TEST_LINE( Transform( SToD("19901202") , "99.99.9999" ) , "1990.12.02" ) TEST_LINE( Transform( SToD("") , "99/99/9999" ) , " . . " ) @@ -1427,6 +1428,7 @@ STATIC FUNCTION Main_STRINGS() SET CENTURY OFF + TEST_LINE( Transform( SToD("20000101") , "@B" ) , "00.01.01" ) TEST_LINE( Transform( SToD("19901214") , "99/99/9999" ) , "90.12.14" ) TEST_LINE( Transform( SToD("19901202") , "99.99.9999" ) , "90.12.02" ) TEST_LINE( Transform( SToD("") , "99/99/9999" ) , " . . " ) @@ -1445,6 +1447,8 @@ STATIC FUNCTION Main_STRINGS() SET CENTURY ON + TEST_LINE( Transform( 1 , "@B" ) , "1 " ) + TEST_LINE( Transform( 1.0 , "@B" ) , "1.0 " ) TEST_LINE( Transform( 15 , "9999" ) , " 15" ) TEST_LINE( Transform( 1.5 , "99.99" ) , " 1.50" ) TEST_LINE( Transform( 1.5 , "9999" ) , " 2" ) diff --git a/harbour/tests/working/run_all.bat b/harbour/tests/working/run_all.bat index 02c0ff5f19..46fb01aa07 100644 --- a/harbour/tests/working/run_all.bat +++ b/harbour/tests/working/run_all.bat @@ -1,9 +1,8 @@ +@echo off rem rem $Id$ rem -@echo off - ..\..\bin\harbour test_all.prg /n /gHBR /i..\..\include runner test_all.hrb hrb call testall.bat diff --git a/harbour/tests/working/setkeys.prg b/harbour/tests/working/setkeys.prg index 979fc19d7e..4fe2acc46b 100644 --- a/harbour/tests/working/setkeys.prg +++ b/harbour/tests/working/setkeys.prg @@ -62,8 +62,8 @@ #endif setKey( K_F10, {|| Alert( transform( getactive():varGet(), NIL ) ) }, {|| !empty( getactive():buffer ) } ) - setKey( K_F9 , {|| k := SetKeySave( NIL ), ; - SetKey( K_F9, {|| SetKeySave( k ) } ) } ) + setKey( K_F9 , {|| k := hb_SetKeySave( NIL ), ; + SetKey( K_F9, {|| hb_SetKeySave( k ) } ) } ) SetKey( K_F8 , {|| SubMain() } ) read @@ -74,7 +74,7 @@ local n SetKey( { 49, 50, 52, 53 }, {|x| qout( chr( x ) ) } ) do while ( n := inkey( 0 ) ) != K_ESC - if SetKeyCheck( n ) + if hb_SetKeyCheck( n ) qqout( " hit hot" ) else qout( chr( n ) )