An open API service indexing awesome lists of open source software.

https://github.com/cristian-5/spin

Spin Programming Language
https://github.com/cristian-5/spin

compiler language quantum-computing quantum-programming-language research

Last synced: 4 months ago
JSON representation

Spin Programming Language

Awesome Lists containing this project

README

        

# Spin - Programming Language

[![license](Resources/Badges/License.svg)](License)
[![version](Resources/Badges/Version.svg)](ReadMe.md)
[![language](Resources/Badges/Language.svg)](ReadMe.md)
[![contributions](Resources/Badges/Contributions.svg)](ReadMe.md)
[![donations](Resources/Badges/Donations.svg)](https://paypal.me/CristianAntonuccio)



High level programming language for *research* in
**Quantum Computing** built in *c++*.

We aim to create a powerful language.

The **Virtual Machine** is ready but the quantum part
of the language is not ready yet;\
Dirac notation has been implemented in the lexer and
preprocessor, but the **VM** doesn't support it yet.

I'm speeding up the development process since this
will be my thesis.

## A taste of spin

These snippets are here to give you a little background
but if you feel lost when it comes to control flow of the
program, just remember that statements work just like in *c++*.

### Numeric Types

![Snippet 1](Examples/S1.svg)

### Minor Types

![Snippet 2](Examples/S2.svg)

The documentation that contains the language syntax
specification is currently under construction.

## Code Contribution

**Attention!** This project is currently under development and
we only completed 70% of the total tasks. We are now working on
the *Quantum System*.

**New Contributors are WELCOME**, so if you're a skilled dev
feel free to contact me for joining our team.

If you want to contribute you must follow these
[Conventions](Conventions/) in order to keep the
file structure organised and the code clean.

## Usage / Help

```
% Spin help magician (it's helpful) %
Usage:
spin
Compiles and executes a file.
spin [-compile, -c]
Compiles a file into a binary.
spin [-decompile, -d]
Decompiles a binary file.
spin [-version, -v]
Shows the version number.
.... [-noAnsi, -n]
Disable ansi output.
: should be the main file and
it should end with '.spin' or
'.sexy' if it's a binary file.
: should be the source file.
: should be the binary file.
I told you it was helpful!
```

## Donations

**Donations** are *welcome*! Offer me a *cup of coffee* since
I drink it *every day* just before working on this project.

[![donations](Resources/Badges/PayPal.svg)](https://paypal.me/CristianAntonuccio)

## Compilation

This code is written in **c++2a** so don't try to build
it using an *older version*.

The **VM** must be compiled using *clang++* and *ninja*.
We don't cover support for *gcc* / *g++* and we don't make
sure that our source will be successfully compiled with them.

We recommend using *clang++* on **macOS** and **Linux**.

The recommended version of *clang++* (**LLVM**) is 9.0.0.