Tabitha Programming Guide

Getting Started

Downloading and Installing the SDK

If you are on a Debian/Ubuntu or Windows system, you can install SDK with one of the Releases. Otherwise, you will need to build from source. For this, you clone the repository,

git clone https://github.com/DeltaBoyBZ/tabitha-sdk

Writing Your First Program

It is traditional, for the first application written in any lanugage to be one which simply prints, “Hello World!” to the console. We see no reason to break this tradition. Create a file hello.tabi, in a new folder tabi-hello (call these anything you like but these are the names we shall use):

attach external std

function main -> Int {
    std::printLn("Hello World!") 
    return 0 
}

The program can be compile with the command:

$ tabic hello.tabi -o bc 

The folder tabi-hello should now look something like this:

tabi-hello
|-- bc
|-- |-- EXTERNAL_std.bc
|-- |-- EXTERNAL_std.o
|-- |-- LOCAL_hello.bc
|-- |-- LOCAL_hello.o
|-- hello
|-- hello.tabi

We of course have our original source file hello.tabi, but there is also now an executable hello. Furthermoree, there is a new folder bc (named by the -o flag), which contains some intermediate binary files. Running the executable, you should see something like this:

$ ./hello
Hello World!