NOTE: THERE IS NO WORKING QUICKBASIC COMPILER HERE.
これはQuickBASIC無いです
No hay recopilador de trabajo de QuickBasic aquí.
Tällä sivulla ei ole QuickBASICia.
This stuff is under development.

QuickBasic compiler clone

QuickBasic compiler clone

0. Contents

This is the documentation of qbc-0.1.1.5.
   1. Purpose
   2. Goals
      2.1. Features not omitted
      2.2. Features supported if possible
      2.3. Features not considered to be supported
      2.4. Features which are gained for free
         2.4.1. Memory allocation
         2.4.2. Hardware services
      2.5. Extra features
         2.5.1. Multitasking
   3. Copying
   4. Requirements
   5. I want to start programming
   6. Downloading

1. Purpose

Tokenizes and parses QuickBasic code. This is under development.

Latest snapshots of the lexer and parser are available:
qb.l // 2002-04-08 (3 kB)
qb.y // 2002-04-08 (8 kB)

If you are interested in joining the development, please contact me.

2. Goals

To provide tools for running QuickBASIC programs in Linux and other non-MS-DOS -environments.

2.1. Features not omitted

These features are often missing from other BASIC implementations, because they are difficult to implement or not seemed as important.

2.2. Features supported if possible

Some of these features require emulation of PC-style hardware without direct hardware access.
  • DEF SEG &HB800/PEEK/POKE support for direct video access in text mode
  • IN/OUT support to ports &H388 - &H389 for AdLib support
  • SCREEN 12/13, PSET and other drawing stuff

2.3. Features not considered to be supported

These QuickBASIC features are not seen as important, and will not be supported (unless somebody has too much time).
  • All the excessive ERR codes like "String formula too complex" etc
  • KEY ON/KEY OFF (dunno about ON KEY)
  • FIELD and other obscure file features (some of which were new in QB 7.0)

2.4. Features which are gained for free

2.4.1. Memory allocation

In modern operating systems, the memory allocation is designed so that the user doesn't have to care about it. We don't have to meddle with EMS/XMS or any other kind of perverse system the hardware requires for memory allocation.
So if you want to say DIM area(1048576) AS INTEGER, it's fine!
Things like VARPTR$ and SADD() will have to be adjusted a bit though.

2.4.2. Hardware services

In *nix systems, all the devices have been designed so that you can use them by just opening the appropiate file from /dev directory. For example, if you wanted to record and play with your soundcard, you could do OPEN "/dev/dsp" FOR BINARY AS #1, and that's fine. You read there (record), you write there (play).
Of course this won't work in Windows systems.
Other examples could be floppy disks, frame buffer consoles etc.
This isn't the whole truth. Some devices require you to do ioctls before you can do anything useful. This will be considered.

2.5. Extra features

There are no plans for extra features yet, but internationalizations like UTF-8 support would be nice.

2.5.1. Multitasking

QuickBasic programs are usually designed to take 100% of the CPU time all the time. This badly fits to multitasking environments we nowadays have in modern operating systems.
But history is history, and we have to support it.
But we don't have to limit ourselves to it. Even if we couldn't detect and convert Ti#=TIMER:WHILE TIMER<Ti#+1:WEND style loops to USLEEP 1000000, we could support things like USLEEP and FORK. Just maybe.
See your favourite POSIX manual if you don't know what those functions mean.

3. Copying

qbc has been written by Joel Yliluoma, a.k.a. Bisqwit,
and is distributed under the terms of the General Public License (GPL).

4. Requirements

At least these GNU tools are required: flex, bison, gcc, make.

5. I want to start programming

Then learn programming. It's a slow journey which requires patience and eagerness to learn new things.

If you want to start programming with BASIC, go and see DarkBasic.

6. Downloading

The official home page of qbc is at http://oktober.stc.cx/source/qbc.html.
Check there for new versions.

Generated from progdesc.php (last updated: Sat, 14 Dec 2002 16:44:09 +0200)
with docmaker.php (last updated: Tue, 13 Aug 2002 14:17:29 +0300)
at Sat, 14 Dec 2002 16:44:18 +0200