A BYTE SHORT TAKE: PowerBasic 2.0
New and Improved Turbo BASIC
 
Microbytes Daily News Service
Copyright (c) 1989, McGraw-Hill, Inc.
Borland assigned the future publishing rights of Turbo BASIC to
original developer Robert Zale, who, along with Spectra
Publishing, will be releasing a new version of Turbo BASIC. I
was able to take a look at a beta version of the new product,
PowerBasic 2.0, although the library, help files, and sample
programs I'd come to associate with Borland products were not
yet available.
 
The look of PowerBasic's main menu and window bears an obvious
family resemblance to the latest versions of Borland's Turbo C
and Turbo Pascal. When you run the compiler all you see is
PowerBasic's main window and main menu; the clutter of multiple
windows in Turbo BASIC is gone. Otherwise PowerBasic functions
much the same as its predecessor.
 
As a superset of Turbo BASIC, PowerBasic 2.0 has many new
features, commands, and functions that gives it substantially
more power and convenience. For example, PowerBasic has binary
coded decimal fixed and floating point data types for 18-digit
accuracy. The compiler also has extended precision (80-bit)
floating point and Quad-word (64-bit) integer data types.
 
You can compile and link separate source code modules for
modular programming. You can link assembly code or object code
from other languages into your programs using OBJ modules.
 
PowerBasic can generate either 8086/88 or 80286 processor code
and supports 80287/387 math coprocessor code in your programs.
It also has an optional procedure-based math package and
Spectra Software claims it performs IEEE-standard floating
point operations faster than a coprocessor emulator.
 
The integrated debugger lets you single-step through your code,
set breakpoints, examine variables, modify expressions, and
monitor the call stack during program execution.
 
One interesting feature of PowerBasic is that you can reduce
the size of your executable file when compiling to disk. You
can select which options to disable, and remove code containing
language features that are not being used in your source code.
This library stripping covers serial communications support,
printer support, all graphics support, CGA, EGA, VGA, and
Hercules graphics support. You can select these options from
the PowerBasic command line, from the Options section of the
main menu, or by inserting a $LIB metastatement in your source
code.
 
I tested out the library stripping feature of PowerBasic with
HANOI.BAS, a 7034-byte sample program from the Turbo BASIC 1.1
package. HANOI.BAS is a simulation of the Towers of Hanoi game
and is an example of recursive programming. When compiled with
Turbo BASIC my HANOI.EXE file was 39642 bytes. With all the
options turned on in PowerBasic, I recompiled the program and
got a file that was 39570 bytes long. With all the options
turned off, the same file compiled to a much smaller 36130
bytes long; a savings of 3440 bytes. This feature can be
especially handy if you're trying to save RAM space or squeeze
a lot of code onto one 360K byte floppy disk.
 
PowerBasic is not a rehash of an existing package. It is a new
and much improved BASIC language compiler. My compliments to
Borland for allowing a third party to support Turbo BASIC
users. It's good to see Turbo BASIC not only resurrected but
improved.
 
The Facts:
PowerBasic 2.0, $109.95
(Registered users of Turbo BASIC 1.1 can upgrade for $50)
 
Spectra Software
1030D E. Duane Ave.
Sunnyvale, CA 94086
(415) 730-9291
 
                              --- Stanley Wszola
 
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
